Technical data
2 
Working with the Target Language
2-18
Conditional Inclusion
The conditional inclusion directives are
%if constant-expression
%else
%elseif constant-expression
%endif
and
%switch constant-expression
%case constant-expression
%break
%default
%endswitch
%if
The constant-expression must evaluate to an integral expression. It controls 
the inclusion of all the following lines until it encounters a 
%else, %elseif, or 
%endif directive. If the constant-expression evaluates to 0, the lines 
following the directive are not included. If the 
constant-expression evaluates 
to any other integral value, the lines following the 
%if directive are included 
up until the 
%endif, %elseif, or %else directives.
When the Compiler encounters an 
%elseif directive, and no prior %if or 
%elseif directive has evaluated to nonzero, the Compiler evaluates the 
expression. If the value is 0, the lines following the 
%elseif directive are not 
included. If the value is nonzero, the lines following the 
%elseif directive are 
included up until the subsequent 
%else, %elseif, or %endif directive.
The 
%else directive begins the inclusion of source text if all of the previous 
%elseif statements or the original %if statement evaluates to 0; otherwise, it 
prevents the inclusion of subsequent lines up to and including the following 
%endif.
The 
constant-expression can contain any expression specified in the “Target 
Language Expressions” section.










