Chapter 9. Diagnosing Problems Within an Exec
. . . . . . . . . . . . . . . . . . . . . . . 111
Tracing Commands with the TRACE Instruction
. . . . . . . . . . . . . . . . . . . . . . . . 111
. . . . . . . . . . . . . . . . . . . . . . . . 112
Using REXX Special Variables RC and SIGL
RC . . . . . . . . . . . . . . . . . . . . . . . . . . . 112
SIGL . . . . . . . . . . . . . . . . . . . . . . . . . . 113
Tracing with the Interactive Debug Facility
Starting Interactive Tracing . . . . . . . . . . . . . . . . . . 114
Options Within Interactive Trace . . . . . . . . . . . . . . . . 116
Ending Interactive Trace . . . . . . . . . . . . . . . . . . . 116
This chapter describes how to trace command output and other debugging
techniques.
Debugging Execs
When you encounter an error in an exec, there are several ways to locate the error.
v
The TRACE instruction displays how the language processor evaluates each
operation. For information about using the TRACE instruction to evaluate
expressions, see “Tracing Expressions with the TRACE Instruction” on page 37.
For information about using the TRACE instruction to evaluate host commands,
see the next section, “Tracing Commands with the TRACE Instruction”.
v
Special variables, RC and SIGL, are set by the system to indicate:
– The return code from a command - (RC)
– The line number from which there was a transfer of control because of a
function call, a SIGNAL instruction, or a CALL instruction - (SIGL)
v
The TSO/E command EXECUTIL TS (Trace Start) and EXECUTIL TE (Trace
End) control the interactive debug facility as do various options of the TRACE
instruction. For more information about interactive debug, see “Tracing with the
Interactive Debug Facility” on page 113.
Tracing Commands with the TRACE Instruction
The TRACE instruction has many options for various types of tracing, two of which
are "commands" or "c" and "error" or "e".
TRACE C
When you specify "trace c" in an exec, any command that follows is traced before it
is executed, then it is executed, and the return code from the command is
displayed.
When an exec without "trace c" issues an incorrect TSO/E command, the exec
ends with a TSO/E error message. For example, a LISTDS command specifies an
incorrect data set name.
"LISTDS ?"
This example results in the following error message.
© Copyright IBM Corp. 1988, 2001
111
Summary of Contents for TSO/E REXX
Page 1: ...z OS TSO E REXX User s Guide SA22 7791 00 ...
Page 2: ......
Page 3: ...z OS TSO E REXX User s Guide SA22 7791 00 ...
Page 10: ...viii z OS V1R1 0 TSO E REXX User s Guide ...
Page 12: ...x z OS V1R1 0 TSO E REXX User s Guide ...
Page 14: ...xii z OS V1R1 0 TSO E REXX User s Guide ...
Page 18: ...xvi z OS V1R1 0 TSO E REXX User s Guide ...
Page 20: ...2 z OS V1R1 0 TSO E REXX User s Guide ...
Page 58: ...Tracing Expressions with the TRACE Instruction 40 z OS V1R1 0 TSO E REXX User s Guide ...
Page 78: ...60 z OS V1R1 0 TSO E REXX User s Guide ...
Page 86: ...Built In Functions 68 z OS V1R1 0 TSO E REXX User s Guide ...
Page 128: ...Issuing Other Types of Commands from an Exec 110 z OS V1R1 0 TSO E REXX User s Guide ...
Page 136: ...Debugging Execs 118 z OS V1R1 0 TSO E REXX User s Guide ...
Page 170: ...Protecting Elements in the Data Stack 152 z OS V1R1 0 TSO E REXX User s Guide ...
Page 201: ...Part 3 Appendixes Copyright IBM Corp 1988 2001 183 ...
Page 202: ...184 z OS V1R1 0 TSO E REXX User s Guide ...
Page 222: ...Using Variables 204 z OS V1R1 0 TSO E REXX User s Guide ...
Page 226: ...208 z OS V1R1 0 TSO E REXX User s Guide ...
Page 238: ...220 z OS V1R1 0 TSO E REXX User s Guide ...
Page 241: ......