DEC Text Processing Utility Program Development
5.7 Debugging DECTPU Programs
After setting breakpoints, use the GO command to switch control of execution
from the debugger to DECTPU. After you have used this command, the screen
displays the code you specified.
5.7.2.2 Debugging Command Files
To invoke the debugger on a command file, use the /DEBUG, /COMMAND, and
/NOSECTION qualifiers. To debug a command file called MY_COMMANDS.TPU,
type the following at the DCL prompt:
$ EDIT/TPU/NOSECTION/COMMAND=MY_COMMANDS.TPU/DEBUG
DECTPU compiles and executes the debugger and places the debug window
on the screen before compiling the command file. As a result, you must set
breakpoints in the command file before it has been compiled. When you set
breakpoints, DECTPU notifies you that you have specified breakpoints at
nonexistent procedures.
To continue with the debugging session, use the GO command. GO causes
DECTPU to compile the contents of the command file. Recompiling a procedure
does not remove any breakpoints set in that procedure.
You cannot use the DECTPU debugger on a file that does not contain DECTPU
procedures. If your command file does not contain any procedures, you must find
a different method of debugging it.
5.7.2.3 Debugging Other DECTPU Source Code
To debug a DECTPU program that is not a section file or a command file, use the
/DEBUG qualifier when you invoke DECTPU. For example, to debug procedures
in a file called USER_APPLICATION.TPU, invoke the debugger on the command
line as follows:
$ EDIT/TPU/DEBUG USER_APPLICATION.TPU
The debugger creates a window that fills the screen as described in
Section 5.7.2.1.
5.7.3 Getting Started with the DECTPU Debugger
This section describes using the default DECTPU debugger with EVE.
If you know which parts of the code you want to debug, use the SET
BREAKPOINT command to set breakpoints. If you need to look at the code
before setting breakpoints, use the GO command as soon as the debugger
window appears. This places on the screen the code in the file you specified
on the command line. At this point, EVE commands are available so you can
manipulate the text. To return to the debugger so you can set breakpoints, enter
the command DEBUG at the EVE command line. You can also gain access to
the debugger with the DECTPU procedure called DEBUGON. To invoke this
procedure from within EVE, type the following at the EVE Command prompt:
Command: TPU DEBUGON
When you use either DEBUG or DEBUGON, the screen displays the debugger
window and command line. After setting breakpoints, use the GO command to
return control of execution to DECTPU.
DEC Text Processing Utility Program Development 5–29