$*$IF expression : statementthe expression is evaluated and if the result is true (non-zero), EXEC executes the statement following the colon. This statement may be a TSS command or EXEC directive. The form
$*$IF expression : statement1 $*$ELSE : statement2is similar. If the expression is non-zero, EXEC executes "statement1"; otherwise it executes "statement2". The colon ":" after $*$ELSE may be omitted.
$*$IF expression1 : statement1 $*$ELseIF expression2 : statement2 $*$ELSE : statement3is yet another form. If "expression1" is non-zero, EXEC executes "statement1". Otherwise, if "expression2" is non-zero, EXEC executes "statement2". Otherwise, EXEC executes "statement3". Any number of $*$ELseIF statements may appear between the $*$IF and the $*$ELSE. Again, the ":" after $*$ELSE may be omitted.
$*$IF expression
statements
$*$ELseIF expression
statements
$*$ELseIF expression
statements
...
$*$ELSE expression
statements
$*$ENDif
lets you execute blocks of statements depending on the value of
expressions.
Statement blocks may contain $*$IF constructs of their own (nested IFs).
See the section "Input Expansion"
in the main explain file "expl exec"
for more details that pertain to $*$IF statements.
Copyright © 2000, Thinkage Ltd.