Marks the beginning of a block of conditional code where execution depends on a macro having not been defined.
This macro preprocessor directive marks the beginning of a block of conditional code where execution depends on a macro having not been defined. It has the form:
where macro-name appears without any leading $$$ characters. Anything following macro-name on the same line is considered a comment and is not parsed.
Execution of the code is contingent on the macro having not been defined. Execution continues until reaching a #else directive or a closing #endif directive. The #elseIf directive is not for use with #ifNDef.
#ifNDef has an alternate name of #ifUnDef. The two names behave identically.
For example, the following provides a simple binary switch based on a macro not having been defined:
#define Multicolor 256
SET NumberOfColors = 2
SET NumberOfColors = $$$Multicolor
WRITE "There are ",NumberOfColors," colors in use.",!