NET/MASTER Network Control Language (NCL) Programmer's Guide

Why Use the DEBUG Commands?
Debugging an NCL Process
106160 Tandem Computers Incorporated 9–3
4. Repeat steps 1 through 3 if an error still exists.
When you are familiar with the DEBUG commands, you will find that they can save
you considerable development time.
Note You can also enter DEBUG commands from an NCL process, by using either the CMD core statement or
the INTCMD verb. Entering NonStop NET/MASTER MS commands from an NCL process is discussed in
Section 16, “Environments and Command Processing.” The syntax of CMD and INTCMD is described in
the NonStop NET/MASTER NCL Reference Manual.
Debugging Different Types
of NCL Processes
Without the DEBUG commands, it is difficult to debug more than one NCL process at
a time from an OCS window. Using the DEBUG START command, which starts a
debug session, you have considerable flexibility when selecting the NCL process(es) to
debug. When starting a debug session, you can target:
A single NCL process in any environment
One or more NCL processes by execution state: currently executing, newly
executed, or both types
NCL processes in a specific window, either a top-level environment or a primary
processing environment
A specific user’s NCL processes, by user ID or terminal name
One or more NCL processes in a background processing environment
One or more NCL processes in a dependent processing environment
NCL processes at a remote system from your local system
Note You cannot debug an NCL process at a remote system that displays a panel.
When you are debugging multiple NCL processes in a single debug session, you can
switch from one to another. This is done by using the DEBUG SET command or
another DEBUG command that specifies an NCL process identifier (NCL ID) to set a
certain NCL process as the current NCL process. Thereafter, subsequent DEBUG
commands do not have to explicitly specify the NCL ID to which the DEBUG
command applies.
You can also start multiple concurrent debug sessions, by using multiple DEBUG
START commands. You can switch between debug sessions by switching between
NCL IDs.
By starting a debug session in one OCS window that targets your other OCS window,
you can debug a MSGPROC NCL procedure or an NCL procedure that displays a
panel. By starting a debug session in both of your OCS windows and swapping from
window to window, you can even debug the same NCL procedure (running
separately) in each window; you can use this technique to develop two different
approaches to finding a bug.