Conditional Compilation

Conditional Compilation

Conditional compilation works similar to the C preprocessor's conditional compilation. The following preprocessor directives may be used:

DirectiveMeaning
#ifdef symbolIf symbol is defined then compile the following code
#ifndef symbolIf symbol is not defined then compile the following code
#elseSwitch from compiling to not compiling and vice versa
#endifReturn to previous compiling state
#if conditionIf the condition evaluates to true then compile the following code
#elifSame as #else but used with #if
Table 7. Conditional compilation directives

See the NXTDefs.h header files for many examples of how to use conditional compilation.


Generated by  doxygen 1.6.2