Previous topic |
Next topic |
Contents |
Contact z/OS |
Library |
PDF
Using the ARG Instruction z/OS TSO/E REXX User's Guide SA32-0982-00 |
|
The function can receive the arguments with the
ARG instruction. Arguments are also separated by commas in the ARG
instruction.
The names of the arguments on the function call and the ARG instruction do not have to be the same because information is not passed by argument name but by position. The first argument sent becomes the first argument received and so forth. You can also set up a template in the function call, which is then used in the corresponding ARG instruction. For information about parsing templates, see Parsing Data. The following exec sends information to an internal function that computes the perimeter of a rectangle. The function returns a value in the variable perim that is specified after the RETURN instruction. The main exec uses the value in perim to replace the function call. Notice the positional relationships between long and length, and wide and width. Also notice that information is received from variable perim to replace the function call. |
Copyright IBM Corporation 1990, 2014
|