At 02:04 AM 9/20/00 +1000, James Sinnamon wrote:
>Dear JDE users and developers,
>
>I have read the JDEbug users guide, but I have not been
>to find a great deal about how to use JDEbug once
>JDEbug has been successfully launched.
>
>I am somewhat familiar with the use of gdb 
>to debug C and C++ programs,
>but I find it hard to apply my knowledge to JDEbug.
>
>For example, how is one supposed to set a breakpoint
>at the start of main, run the program, hit the
>breakpoint, then continue, one statement at a time?
>
>I have been unable to do this, so I don't feel very 
>confident about attempting to use more sophisticated 
>debugging techniques.
>
>My breakpoints are nearly always are ignored no matter 
>how I try to run the program, and even when my program 
>stops, I don't see the JDEbug "Step Over" or "Step Into"
>menu items highlighted.  When I select "Continue", being
>the only applicable ative item on the menu, the 
>program will usually continue to the end.
>
>Would anyone be able to either:
>
>(1) Show me where to find documentation which 
>explains how to run JDEbug once it has started,
>and give me some idea of whatis going on; or
>
>(2) Suggest how I could work out what is wrong 
>with my JDEbug setup.
>

Hi James,

Here is the relevant section from the JDEbug User's Guide:

------------------------------------------------------------------------
Launching a Process

In this guide, a process refers to a running instance of an application.
JDEBug provides two commands for launching processes.

JDEbug->Processes->Launch Process 

This command launches an instance of the application whose main class is
specified by the variable jde-run-application-class, or, if this variable
is nil, the application in the current Java source buffer. The debugger
suspends the debuggee process before it enters the application's main
method. At this point, you should set one or more breakpoints in the
application and select the Run command from the JDEbug menu. The process
will then run to the first breakpoint at which point you can continue to
the next breakpoint or single-step the process.


JDE->Debug App 

This command performs the following actions:


Starts the debugger, if necessary. 
Launches the application. 
Sets any breakpoints you have previously specified (see Setting Breakpoints). 
Runs the application. 

Note With this command, the application will simply run to completion
without stopping, if you have not previously specified any valid
breakpoints for the application or none of the breakpoints exist on the
main execution path.
----------------------------------------------------------------------------
----

Could you please explain to me what you find puzzling or unclear about this
explanation so that I can improve it for future releases of the JDE?

If you find this explanation clear, could you please explain exactly what
steps you took to set breakpoints and turn the application?

Your problem report shows no signs of your ever having set a breakpoint,
either before starting the debug session or afterwards. Thus, it is not
surprising that your application simply runs to completion when you issue a
run command, either directly or indirectly via JDE->Debug App.


- Paul

Reply via email to