Skip to main content



      Home
Home » Language IDEs » C / C++ IDE (CDT) » Setting breakpoint on exceptions when debugging
Setting breakpoint on exceptions when debugging [message #100307] Mon, 19 April 2004 23:26 Go to next message
Eclipse UserFriend
How can I stop the debugger when codethrows an exception? I.e., stop when
__cxa_throw is encountered (GNU C++). I use this all the time in GDB to
identify the procedure that threw and inspect the stack. I have tried to
"open" the executable in C++ Projects and do "add/remove breakpoint" but
that does not seem to do anything. The Java exception icon doesn't either.

Also why do all my executable show twice in that C++ Project directory (all
executables under "bin" directory in the workspace)?

Thanks, Pierre
Re: Setting breakpoint on exceptions when debugging [message #100444 is a reply to message #100307] Tue, 20 April 2004 19:34 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: alain.nowhere.ca

Pierre Belzile wrote:

> How can I stop the debugger when codethrows an exception? I.e., stop when
> __cxa_throw is encountered (GNU C++). I use this all the time in GDB to

Yes this is gcc specifics, we are looking at ways to make this possible
the problem is how to make this exception specific, I mean you do
not want to stop __all__ the times but rather on a specific exception
like io exception or memory exception. The problem is to know
what exception was trigger ... not easy since this compiler specific
and opaque data.

> identify the procedure that threw and inspect the stack. I have tried to
> "open" the executable in C++ Projects and do "add/remove breakpoint" but
> that does not seem to do anything.

hmm file a PR, you could alternatively switch to gdb console and
set your breakpoint.

> The Java exception icon doesn't either.

Well no ... this is Java specific(JDT) nothing to do with C/C++

> Also why do all my executable show twice in that C++ Project directory (all
> executables under "bin" directory in the workspace)?

This can be a bug, or ... you have two executables 8-) one in the release
version and one in the debug version.
Re: Setting breakpoint on exceptions when debugging [message #100485 is a reply to message #100444] Tue, 20 April 2004 22:45 Go to previous message
Eclipse UserFriend
alain wrote:

> Pierre Belzile wrote:
>
>> How can I stop the debugger when codethrows an exception? I.e., stop when
>> __cxa_throw is encountered (GNU C++). I use this all the time in GDB to
>
> hmm file a PR, you could alternatively switch to gdb console and
> set your breakpoint.
>
I had not realized the console was 2-way. Thanks for the suggestion. This
will make DDD history. Excellent work.

Cheers, Pierre
Previous Topic:linux cdt_1_2 branch build
Next Topic:how to search newsgroup&cross compiler
Goto Forum:
  


Current Time: Fri Jul 18 13:02:50 EDT 2025

Powered by FUDForum. Page generated in 0.28692 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top