can't find class named `foo', as given by C++ RTTI

Benjamin Kosnik
Fri Jun 29 11:34:00 GMT 2001

> > In this case, GDB wasn't able to find the name std::numpunct.


> > Probably GDB should have been able to find std::numpunct.  

Definitely, GDB should be able to find std::numpunct.

> > But does
> > the rest of the process look reasonable?  That is, was the run-time
> > type of *__fp indeed `std::numpunct'?  The output from `ptype'
> > suggests that its compile-time type is `class facet'.  Perhaps
> > something went wrong well before we ever tried to look up the type
> > name.
> Nope. The name of the type in the symbol table is numpunct<char>,
> because of scoping problems.

Right. The ptype output is the base class, not what I really want to see. 
I'd like to be able to look at the contents of the object, for instance. 
I think this is a reasonable request.

You might want to look at this:

There's been some discussion on this thread: I'll give you a bit of time 
to catch up.


More information about the Gdb mailing list