Aleph-w 3.0
A C++ Library for Data Structures and Algorithms
Loading...
Searching...
No Matches
ahAssert.H File Reference

Debug assertion and warning utilities. More...

#include <cstddef>
#include <cstdlib>
#include <cstdio>
#include <cassert>
Include dependency graph for ahAssert.H:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define COND_ASSERT(cond, f, args...)
 Conditional assertion macro (no-op in release).
 
#define DEBUGINFO(p)
 Debug information macro (no-op in release).
 
#define PRINT_TRACE(p)   (p)
 Print trace macro (active in release builds).
 

Detailed Description

Debug assertion and warning utilities.

Provides debug-only assertion and warning macros that are compiled out in release builds. When DEBUG is defined, assertions print diagnostic information and abort the program. Warnings print diagnostic information without aborting.

Note
These macros are only active when the DEBUG preprocessor symbol is defined.
Author
Leandro Rabindranath León

Definition in file ahAssert.H.

Macro Definition Documentation

◆ COND_ASSERT

#define COND_ASSERT (   cond,
  f,
  args... 
)

Conditional assertion macro (no-op in release).

Definition at line 142 of file ahAssert.H.

◆ DEBUGINFO

#define DEBUGINFO (   p)

Debug information macro (no-op in release).

Definition at line 145 of file ahAssert.H.

◆ PRINT_TRACE

#define PRINT_TRACE (   p)    (p)

Print trace macro (active in release builds).

Parameters
pThe statement to execute.

Definition at line 150 of file ahAssert.H.