The COBOL-IT Debugger Engine (cobcdb)
The COBOL-IT Debugger Engine (cobcdb
) has been designed to operate as an engine, working in the background, behind a user interface, such as the interface that is provided by the COBOL-IT Debugging Perspective in the Developer Studio. The COBOL-IT Debugger Engine (cobcdb
) runs shared object files that have been created by the COBOL-IT Compiler (cobc
) and that have been compiled with the –g
compiler flag.
Conventions Used
The Debugger Prompt
When you start the COBOL-IT Debugger Engine, the COBOL-IT Debugger Window presents a prompt, into which a Debugger Command can be entered. After entering a Debugger Command, the user will see the results of their command returned, with a subsequent debugger prompt. The default debugger prompt is (cobcdb
).
To illustrate:
C:\COBOL\COBOLIT\samples>cobcdb hello
CreateProcess "cobcrun -d hello ".
command:11516
(cobcdb)
event:11516
-event-end-stepping-range #0 hello () at C:/COBOL/COBOLIT/samples/hello.cbl!8
The debugger prompt is here. As an example, enter the version command:
version
~"COBOL-IT cobcdb 3.6.4\n"
^done
(cobcdb)
Enter a subsequent command here.
Source Location
Source Location is formatted as:
<Absolute source path name>!<line number>
Example:
C:/COBOL/COBOLIT/samples/hello.cbl!21
Variables names
<variable-name>
is formatted as:
[@<module-name>.][<section>.][<upper-level-fields >.]<field-name>
If no <module-name>
is given, current module is searched.
If no <section>
is given, sections are searched in the following order:
- file section
- working-storage section
- linkage-section.
If no <upper-level-field>
is given, the first matching field as presented in the original source is returned.
Example:
WORKING-STORAGE.WrkA.Wrk_G1.Wrk_G1_F1 or Wrk_G1.Wrk_G1_F1
is equivalent to
@PrgA.WORKING-STORAGE.WrkA.Wrk_G1.Wrk_G1_F1
where declarations are:
working-storage section.
01 WrkA.
03 Wrk_F1 PIC 99.
03 Wrk_F2 PIC 99.
03 Wrk_G1.
05 Wrk_G1_F1 PIC 99.
05 rk_G1_F2 PIC 99.