A constant conditional expression is an expression used in the ISO2002 conditional compilation directives, DEFINE, EVALUATE,
and IF, and determines the text that is included in the resultant program.
Note: In this context, literals also refer to compilation variables, which means that you can use compilation variables in constant
conditional expressions.
A constant conditional expression can be one of the following:
- A relation condition in which both operands are literals or arithmetic expressions that contain only literal terms. The condition
must follow the rules for relation conditions, with the following additions:
- All operands must be of the same category. (An arithmetic expression is of the category numeric.)
- If non-numeric literals are specified, the relational operator shall be "IS EQUAL TO", "IS NOT EQUAL TO", "IS =", "IS NOT
=", or "IS <>".
- A defined condition.
- A Boolean condition.
- A complex condition formed by combining the above forms of simple conditions into complex conditions by using AND, OR, and
NOT. Abbreviated combined relation conditions cannot be specified.