.IF, .ELSE, and .ENDI

Begin if condition.

.IF expression [ THEN]

stmtlist

[ .ELSE

stmtlist]

.ENDI

Remarks

If expression is true, execute stmtlist following THEN (the keyword THEN is optional); if expression is false, execute stmtlist following .ELSE, if present; otherwise, advance to the instruction following .ENDI.

In the case of nested .IF- THEN- .ELSE statements, each .ELSE refers to the most recent .IF- THEN sequence.

Example

.IF <EQ> ; zero bit set?

...ENDI