Different assert macros.
More...
Go to the source code of this file.
|
| void | AssertFunctionPrintf (const char *filename, int lineNumber, const char *message,...) |
| | If the assert fails, break into assert display loop and ask if assert should be ignored.
|
| |
| void | AssertFunctionPrint (const char *filename, int lineNumber, const char *message) |
| | If the assert fails, break into assert display loop and ask if assert should be ignored.
|
| |
◆ mgdl_assert_print
| #define mgdl_assert_print |
( |
|
test, |
|
|
|
message |
|
) |
| |
Value:if ((test) == false) \
{ \
AssertFunctionPrint(__FILE__, __LINE__, message); \
}
◆ mgdl_assert_printf
| #define mgdl_assert_printf |
( |
|
test, |
|
|
|
message, |
|
|
|
... |
|
) |
| |
Value: if ((test) == false) \
{ \
AssertFunctionPrintf(__FILE__, __LINE__, message, __VA_ARGS__); \
}
◆ mgdl_assert_test
| #define mgdl_assert_test |
( |
|
test | ) |
|
Value:if ((test) == false) \
{ \
AssertFunctionPrint(__FILE__, __LINE__, #test); \
}
◆ AssertFunctionPrint()
| void AssertFunctionPrint |
( |
const char * |
filename, |
|
|
int |
lineNumber, |
|
|
const char * |
message |
|
) |
| |
If the assert fails, break into assert display loop and ask if assert should be ignored.
This function is called by the gdl_assert macro. It breaks normal execution and loops showing the provided error message until user selects to ignore the assert or quit the program.
- Parameters
-
| filename | The filename of the code where assert happened. This is provided by FILE macro. |
| lineNumber | Line in code where assert happened. This is provided by LINE macro. |
| message | The message to show when assert fails. |
◆ AssertFunctionPrintf()
| void AssertFunctionPrintf |
( |
const char * |
filename, |
|
|
int |
lineNumber, |
|
|
const char * |
message, |
|
|
|
... |
|
) |
| |
If the assert fails, break into assert display loop and ask if assert should be ignored.
This function is called by the gdl_assert macro. It breaks normal execution and loops showing the provided error message until user confirms
- Parameters
-
| filename | The filename of the code where assert happened. This is provided by FILE macro. |
| lineNumber | Line in code where assert happened. This is provided by LINE macro. |
| message | The message to show when assert fails. Has to contain format specifiers. |
| __VA_ARGS__ | Arguments for the format specifiers in message. |