StuBS
|
Macros | |
#define | STRINGIFY(S) #S |
Converts a macro parameter into a string. | |
#define | assert_size(TYPE, SIZE) static_assert(sizeof(TYPE) == (SIZE), "Wrong size for " STRINGIFY(TYPE)) |
Statically ensure (at compile time) that a data type (or variable) has the expected size. | |
#define | assert(EXP) |
Ensure (at execution time) an expression evaluates to true , print an error message and stop the CPU otherwise. | |
#define | kernelpanic(MSG) |
Print an error message in the debug window and stop the current core. | |
#define assert | ( | EXP | ) |
Ensure (at execution time) an expression evaluates to true
, print an error message and stop the CPU otherwise.
EXP | The expression to be checked |
#define assert_size | ( | TYPE, | |
SIZE ) static_assert(sizeof(TYPE) == (SIZE), "Wrong size for " STRINGIFY(TYPE)) |
Statically ensure (at compile time) that a data type (or variable) has the expected size.
TYPE | The type to be checked |
SIZE | Expected size in bytes |
#define kernelpanic | ( | MSG | ) |
Print an error message in the debug window and stop the current core.
MSG | error message |
#define STRINGIFY | ( | S | ) | #S |
Converts a macro parameter into a string.
S | Expression to be converted |