pTAL Reference Manual (G06.24+, H06.09+, J06.03+)
Variables (including structure data items) are byte addressed or word addressed as follows:
Byte addressed
• STRING simple variables
• STRING arrays
• Variables to which STRING simple pointers point
• Variables to which STRING structure pointers point
• Substructures
Word addressed
• INT, INT(32), FIXED, REAL, or REAL(64) simple variables
• INT, INT(32), FIXED, REAL, or REAL(64) arrays
• Variables to which INT, INT(32), FIXED, REAL, or REAL(64) simple pointers point
• Variables to which INT structure pointers point
• Structures
After a move, next-addr might point to the middle of an element, rather than to the beginning
of the element. If destination is word addressed and source is byte addressed and you
copy an odd number of bytes, next-addr will not point to an element boundary.
RETURN
A RETURN statement causes a procedure or function to return control to its caller. When you return
from a function, the RETURN statement also specifies a value to return to the function’s caller.
NOTE:
• In the discussion of the RETURN statement, the word “procedure” implies both procedures
and subprocedures but not functions.
• The EpTAL compiler issues a warning whenever a pTAL procedure returns both a
result-expression and a cc-expression and has the procedure attribute RETURNSCC
(see Procedure Attributes (page 248)). The reason for this warning is in Appendix D (page 528).
cc-expression
is an INT expression whose numeric value specifies the condition code value to return to the
caller:
The condition code is set to ...Value of cc-expression
Less than (<)Less than 0
Equal (=)Equal to 0
Greater than (>)Greater than 0
Specify cc-expression in RETURN statements only in functions and procedures that specify
the attribute RETURNSCC (see Procedure Attributes (page 248)).
RETURN 223