Small changes

This commit is contained in:
Krzosa Karol
2024-01-29 12:29:19 +01:00
parent 1617135e65
commit 61967d16ad
4 changed files with 6 additions and 9 deletions

View File

@@ -58,9 +58,9 @@ int main(int argc, char **argv) {
Array<S8_String> flags = {scratch}; Array<S8_String> flags = {scratch};
flags += "-g -Wno-write-strings"; flags += "-g -Wno-write-strings";
flags += "-fdiagnostics-absolute-paths"; flags += "-fdiagnostics-absolute-paths";
flags += "-fno-exceptions"; flags += "-fsanitize=address";
if (is_cpp) flags += "-fno-exceptions";
if (is_cpp) flags += "-fno-rtti"; if (is_cpp) flags += "-fno-rtti";
if (is_cpp) flags += "-fsanitize=address";
if (is_cpp) flags += "-std=c++11"; if (is_cpp) flags += "-std=c++11";
flags += Fmt("-o %.*s", S8_Expand(exe)); flags += Fmt("-o %.*s", S8_Expand(exe));

View File

@@ -32,6 +32,7 @@ typedef enum IO_ErrorResult {
#define IO__PrintfFormat(fmt, va) #define IO__PrintfFormat(fmt, va)
#endif #endif
typedef void IO_MessageHandler(int kind, const char *file, int line, char *str, int len);
extern void (*IO_User_OutputMessage)(int kind, const char *file, int line, char *str, int len); extern void (*IO_User_OutputMessage)(int kind, const char *file, int line, char *str, int len);
#define IO__STRINGIFY(x) #x #define IO__STRINGIFY(x) #x
@@ -83,8 +84,8 @@ IO_API IO_ErrorResult IO_OutputError(char *str, int len);
IO_API void IO_Exit(int error_code); IO_API void IO_Exit(int error_code);
IO_API bool IO_IsDebuggerPresent(void); IO_API bool IO_IsDebuggerPresent(void);
const int IO_KindPrintf = 1; static const int IO_KindPrintf = 1;
const int IO_KindWarningf = 2; static const int IO_KindWarningf = 2;
#define IO_Printf(...) IO__Printf(IO_KindPrintf, __FILE__, __LINE__, __VA_ARGS__) #define IO_Printf(...) IO__Printf(IO_KindPrintf, __FILE__, __LINE__, __VA_ARGS__)
#define IO_Warningf(...) IO__Printf(IO_KindWarningf, __FILE__, __LINE__, __VA_ARGS__) #define IO_Warningf(...) IO__Printf(IO_KindWarningf, __FILE__, __LINE__, __VA_ARGS__)

View File

@@ -113,8 +113,4 @@
#error couldnt figure out OS #error couldnt figure out OS
#endif #endif
// #if COMPILER_CLANG
// #pragma clang diagnostic push
// #pragma clang diagnostic ignored "-Wmicrosoft-enum-forward-reference"
// #endif
#endif #endif

View File

@@ -99,7 +99,7 @@ enum {
S8_SplitFlag_SplitInclusive = 2, S8_SplitFlag_SplitInclusive = 2,
}; };
const bool S8_IgnoreCase = true; static const bool S8_IgnoreCase = true;
#if defined(__has_attribute) #if defined(__has_attribute)
#if __has_attribute(format) #if __has_attribute(format)