TAL Reference Manual
TAL Reference Manual—526371-001
14-1
14 Standard Functions
TAL provides a variety of standard functions that perform frequently used operations.
This section describes the syntax for calling each standard function.
For information on privileged standard functions—$AXADR, $BOUNDS, and
$SWITCHES—see Section 15, Privileged Procedures
.
Summary of Standard Functions
Standard functions—also known as built-in functions—perform a variety of operations.
The following table describes the operations by category:
Identifiers of standard functions begin with a dollar sign ($).
Table 14-1
on page 14-2 lists the standard functions by category and summarizes what
they do. Table 14-2
on page 14-4 cross-references the type-transfer functions by data
type.
In both tables, INT and INT(32) expressions can also include operands of the following
data types:
•
INT expressions can include operands of data types STRING, INT, and
UNSIGNED(1–16).
•
INT(32) expressions can include operands of data types INT(32) and
UNSIGNED(17–31).
For more information, see Expression Arguments
on page 14-5.
Category Operation
Type transfer Converts an expression from one data type to another
Address conversion Converts standard addresses to extended addresses or
extended addresses to standard addresses
Character test Tests for an alphabetic, numeric, or special ASCII character;
returns a true value if the character passes the test or a false
value if the character fails the test
Minimum-maximum Returns the minimum or maximum of two expressions
Carry and overflow Tests the state of the carry or overflow indicator in the
environment register; returns a true value if the indicator is on
or a false value if it is off
FIXED expression Returns the fixed-point setting, or moves the position of the
implied decimal point, of a FIXED expression
Variable Returns the unit length, offset, data type, or number of
occurrences of a variable
Miscellaneous Tests for receipt of actual parameter; returns the absolute
value or one’s complement from expressions; returns the
setting of the system clock or internal register pointer