TOC PREV NEXT INDEX DOC LIST MASTER INDEX




filled in New View dialog box (graphics)


filled in New C++ dialog box (graphics)


C/C++ editor window-debugger (text and graphics)

The C++ editor window is where you write, edit, compile, and link code. Files created by Apex contain a comment line identifying the file, along with a stub that is ready for you to fill in.

The display area of the C++ editor window for area.C looks like this:

Using the editor:


Enter the C++ main program to debug

1. . Use the C/C++ editor window containing the area.C file.

2. . Delete the "int main (int argc, char* argv[])" line and the lines with curly brackets.

3. . Enter the following code:



Generate the executable file

Generate an executable program to be used by the debugger.

1. . Select the Compile:Code command

The Jobs window for the code command displays the code job.

The Message window for the successful code command displays a log of the command.


2. . Select the Compile:Link command

The Jobs window for the link command displays the link job.

The Message window for the successful link command displays a log of the command.

The executable is displayed in the project1.ss/area.wrk directory viewer in the form area*.

Note: If you have made changes to the file, Apex automatically saves the changes as part of the Code or Link operation.



Debug dialog box (graphics)


Debugger Main Window (text and graphics)

The Debugger Log window is the main Apex debugger window. When you conduct a debugging session, all interactions with the debugger are displayed in a sequential log in this Debugger window.

The section below the log window is called the Command Pane. This area can be used to enter debugger commands through the keyboard. Commands available through this interface are discussed in detail in Using the Apex Debugger.

Information about the current program being debugged can also be displayed in a status line at the bottom of the Debugger Window. If it is not present, select the View:Show Status Pane command. A new area will appear at the bottom of the window containing the following information about the current program:

An additional window is also available for display within the main Debugger window. This window is called the Source pane. The Source pane is used to display program source text. Use of this window allows you to do all your debugger operations within the Debugger Window, without using an external editor. You will be displaying the Source Pane shortly in this tutorial.


C/C++ Editor Window (graphics)


Input/Output Window (graphics)


Source Pane (graphics)

The Apex debugger can be configured to behave in one of two modes for the display of source code: either through one of the editors or through its own source pane in the debugger window. You can configure the default source display method when the debugger starts up and you can toggle between modes during a debugging session by using the View:Show Source command.

Using an Apex editor to display source allows you to retain the full capabilities of the editor while you're debugging. For example, you can perform Summit/CM, compilation, or editing operations during a debugging session.This display mode is called editor mode. It is the default.

The debugger's source display is optimized for debugging. It doesn't provide facilities for editing, compilation, or source control, for example. It does provide extra features specifically designed for debugging. For example, it contains source indicators that show where breakpoints are set. This mode is called Show Source mode.


Debugger Window (graphics)


Breakpoints Window (graphics)

The Breakpoints window displays all the currently defined breakpoints. The window has an active area that displays the active breakpoints and an inactive area that displays the inactive breakpoints. When a breakpoint is active, it is installed in the program being debugged and will stop a task in which execution reaches the location where the breakpoint is placed (and any task, trip count, or breakpoint conditions are satisfied). When a breakpoint is inactive, it has no effect on the execution of the program.

The Debug:Break Here command creates permanent, active breakpoints. You have created breakpoint 1, an active breakpoint listed in the Active area in the Breakpoints window.


Debugger Window (graphics)

If source mode is on, whenever the execution of a C/C++ function stops, the default is:

If editor mode is on, whenever the execution of a C/C++ function stops, the default is:


Execution:Step Into (graphics)


Show Data dialog box (graphics)


Show Location (graphics)


Modify Data dialog box (graphics)


filled in Modify Data dialog box (graphics)


File:Disassembly (graphics)


Rational Software Corporation 
http://www.rational.com
support@rational.com
techpubs@rational.com
Copyright © 1993-2001, Rational Software Corporation. All rights reserved.
TOC PREV NEXT INDEX DOC LIST MASTER INDEX TECHNOTES APEX TIPS