19 #ifdef SAMURAI_WINDOWS
24 int line,
const char *comment)
26 char buffer[1024] = {};
28 std::snprintf(buffer,
sizeof(buffer),
29 "Assertion failed\n\n"
31 "Expression: \n%s\n\n"
38 "Press retry to debug."
45 int const action = MessageBoxA(0, buffer,
"Pika error", MB_TASKMODAL
46 | MB_ICONHAND | MB_ABORTRETRYIGNORE | MB_SETFOREGROUND);
75 int line,
const char *comment)
78 char buffer[1024] = {};
80 std::snprintf(buffer,
sizeof(buffer),
81 "Assertion failed\n\n"
83 "Expression: \n%s\n\n"
90 "Please report this error to the developer."
98 int const action = MessageBoxA(0,
99 buffer,
"Pika error", MB_TASKMODAL
100 | MB_ICONHAND | MB_OK | MB_SETFOREGROUND);
106 void assertFunctionToLog(
const char *expression,
const char *file,
int line,
const char *comment)
109 char buffer[1024] = {};
111 std::snprintf(buffer,
sizeof(buffer),
void assertFunctionDevelopment(const char *expression, const char *file, int line, const char *comment=nullptr)
void assertFunctionProduction(const char *expression, const char *file, int line, const char *comment=nullptr)
void assertFunctionToLog(const char *expression, const char *file, int line, const char *comment=nullptr)
void logToFile(const char *fileName, const char *l, int type=samurai::logNormal)
static constexpr const char * DefaultLogFile