pTAL Reference Manual (H06.08+)
Compiler Directives
HP pTAL Reference Manual—523746-006
17-39
IF and IFNOT
behavior prevents the pTAL compiler from using GP-relative addressing for references
to data in an SRL.
IF and IFNOT
IF and IFNOT identify the beginning of code that is to be conditionally compiled.
toggle-name
was specified by one of the following:
•
DEFINETOG on page 17-27
•
SETTOG on page 17-58
•
RESETTOG on page 17-54
IF compiles the conditional code only if toggle-name is on.
IFNOT compiles the conditional code only if toggle-name is off.
The EpTAL compiler allows toggle-name to be RISC1, _TNS_E_TARGET, or
TARGETSPECIFIED, as long as toggle-name does not change the value of
target in the IF, IFNOT, or ENDIF statement.
toggle-number
is an unsigned decimal constant in the range 1 through 15. Leading zeros are
ignored.
IF compiles the conditional code only if toggle-name is on.
Example 17-20. GP_OK, NOGP_OK, PUSHGP_OK, and POPGP_OK Directive
?PUSHGP_OK
?NOGP_OK
?NOEXPORT_GLOBALS
BLOCK a_block;
...
END BLOCK;
?EXPORT_GLOBALS
?POPGP_OK
VST694.vsd
pTAL
target
IF
IFNOT
toggle-number
toggle-name










