pTAL Reference Manual (H06.08+)
Built-In Routines
HP pTAL Reference Manual—523746-006
15-76
$OVERFLOW
$OVERFLOW
$OVERFLOW returns a value indicating whether an overflow occurred during certain
arithmetic operations.
$OVERFLOW indicates whether an overflow occurred. You can test $OVERFLOW
only if overflow traps are disabled and only following an assignment statement in which
the final operator executed on the right side of the assignment is one $FIX of a REAL
or REAL(64) value of the following operators or built-in routines:
•
Negate (unary -), +, -, *, /,’/’
•
$DBL of an INT, FIXED, REAL, or REAL(64) value
•
$FLTR of a REAL(64) value
•
$FIX of a REAL or REAL(64) value
•
$FIXD
•
$FIXI
•
$FIXL
•
$FIXR of a REAL or REAL(64) value
•
$INT of a FIXED, REAL, or REAL(64) value
•
$INT of a FIXED, REAL, or REAL(64) value
•
$INTR of a FIXED, REAL, or REAL(64) value
•
$SCALE, for which: 1 <= exponent <= 4
PROC p2 (p, q) EXTENSIBLE;
INT .p;
INT .q;
BEGIN
! Lots of code
CALL p1 ($OPTIONAL ($PARAM (p), p ),
$OPTIONAL ($PARAM (q), q ));
! Lots of code
END;
pTAL privileged procedure No
Can be executed only by privileged procedures No
Sets condition code No
Sets $CARRY No
Sets $OVERFLOW No
Example 15-71. $OPTIONAL Routine for a Front-End Interface (page 2 of 2)
VST105.vsd
$OVERFLOW










