ASSERT(D3)
ASSERT - verify assertion
As shipped in IRIX 6.5.7. Unchanged since IRIX 6.5.
NAME ASSERT - verify assertion SYNOPSIS #include <sys/debug.h> #include <sys/ddi.h> void ASSERT(int expression); Arguments expression Expression to be evaluated. DESCRIPTION ASSERT is a debugging interface for verifying program invariants within code that is compiled with the DEBUG compilation option defined. Return Values If expression evaluates to non-zero, ASSERT returns no value. If expression evaluates to zero, ASSERT panics the system. USAGE expression is a boolean expression that the caller expects to evaluate to non-zero (that is, the caller is asserting that the expression has a non-zero value). If expression evaluates to non-zero, the ASSERT call has no effect. If expression evaluates to zero, ASSERT causes the system to panic with the following message: PANIC: assertion failed: expression, file: filename, line: lineno where filename is the name of the source file in which the failed assertion appears and lineno is the line number of the ASSERT call within the file. When the DEBUG compilation option is not defined, ASSERT calls are not compiled into the code, and therefore have no effect, including the fact that expression is not evaluated. Level Initialization, Base or Interrupt. Synchronization Constraints Does not sleep. Driver-defined basic locks, read/write locks, and sleep locks may be held across calls to this function. REFERENCES cmn_err(D3)