This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: std::string and MI
- From: Daniel Jacobowitz <drow at false dot org>
- To: André Pönitz <apoenitz at trolltech dot com>
- Cc: gdb at sources dot redhat dot com
- Date: Wed, 3 Dec 2008 12:27:00 -0500
- Subject: Re: std::string and MI
- References: <200811271339.03070.apoenitz@trolltech.com>
On Thu, Nov 27, 2008 at 01:38:56PM +0100, André Pönitz wrote:
> I get after issuing a "-stack-list-locals 2" the response
>
> ^done,locals=[{name="s",type="string"},{name="f",type="foo::string"},
> {name="t",type="string"}]
>
> Similarily, "-var-create s * s" followed by "-var-info-type s" produces
>
> ^done,type="string"
>
> In both cases the 'std::' namespace is missing from the type.
I'll second Tom - I think I opened a GCC bug report about this.
> Incidentally: Would it be possible to extend the MI commands that output
> types to also produce the mangled types? (This could be restricted to the
> cases where these actually differs from the unmangled ones, but I really
> don't mind duplicated output)
There's not really any such thing in the debug info. Some GCC debug
info includes mangled names for functions, but it's not always there
and it is never present for types. We'd have to reconstruct it from
linkage names and map to parameters; it would be very hit-or-miss.
--
Daniel Jacobowitz
CodeSourcery