assert()

Syntax:

#include <assert.h>
void assert( int exp );



Description:
The assert() macro is used to test for errors. If exp evaluates to zero, assert() writes information to STDERR and exits the program. If the macro NDEBUG is defined, the assert() macros will be ignored.

Related Topics:
abort()

Vadim avatar

Vadim