Introduction
Some macros such as assertion with message.
Examples
test_msg.cpp
{
int a = 1;
int b = 2;
limboPrint(limbo::kDEBUG,
"a = %d, b = %d\n", a, b);
limboAssertMsg(a+b < 3,
"a+b fails to be less than 3: a+b = %d", a+b);
return 0;
}
Compiling and running commands (assuming LIMBO_DIR is exported as the environment variable to the path where limbo library is installed)
1 g++ -o test_msg test_msg.cpp -I $LIMBO_DIR/include
Output
2 (A) test_msg.cpp:14: int main(): Assertion `a+b < 3' failed: a+b fails to be less than 3: a+b = 3
References