This is the mail archive of the gdb@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Move GDB to C++ ?


Vladimir Prus wrote:
Joel Brobecker wrote:

I am way out of my league on this, but isn't it the case that:
- there's still some progress to be made to help debugging C++
in general (I might be VERY wrong on that one)


These are good points. They offer pointers to some of the areas that GDB is lacking. The cheap comment to make here though is that, were GDB written in C++ and used these features, we'd have these debugging problems fixed - of course, for instance, GDB is managing to be a good Ada debugger, without being written in Ada :-)


This does, I think, raise an interesting question: is, or should, be being the a good (best?) C++ debugger be a high priority for GDB?


I think that the biggest issue with debugging C++ is that whenever you
have pointer to class Base, which actually points to object of class
Derived, and you want GDB to print the real type, GDB gives fits.
(Or maybe, I'm not sufficiently trained in asking GDB politely).

Second issue is that I don't think "step" via throw statement works -- you
need "catch catch".

I don't think the above issues are showstoppers -- there are workarounds,
and the issues must be fixed anyway.

The inline functions are not specific to C++, and templates -- well, there
are no issues debugging templates, and who needs templates outside of (well-debugged already) STL, anyway (*)?


Last time I checked, GDB had some bizarre logic to handle C++ namespaces,
but well, who needs namespaces (*)?

- Volodya

(*) Both templates and namespaces have important uses; but it does not seem
GDB, specifically, has much need of them.






Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]