4.3.3.1  ASSERT Macros

The format of an ASSERT macro is as follows.

ASSERT (Expression);

 

If Expression evaluates to FALSE, the macro displays a message in the WinDbg KD Command window. The message displays the source-code string of the expression that evaluated to FALSE, as well as the path of the source-code file and the line number in that file of the instruction that called the macro. You can then choose to break into the debugger, ignore the ASSERT, or terminate the process or thread in which the ASSERT occurred. If you break into the debugger, you can trace the stack frames, dump or edit memory, and so on. If you choose to ignore the ASSERT, execution continues as if you had entered the g command.

In a free builds of the driver, the ASSERT macro is not compiled.