This is the mail archive of the gdb@sources.redhat.com 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]

bad demangling, strange line numbers, caused by...?



Using current CVS gdb to debug some code built with current CVS g++.
(The code is a varation on "hello world" meant to point out some redirecting
bugs in the library; it's nothing wacky.)

Trying to step into a function gives me undemangled symbols (I thought that
the autodetection was on now?), and then an "out of range" line number
which I've never seen before.  Pressing Enter (marked as <CR> below)
still gets me into that function correctly, however.

    (gdb) n
    8           std::cout << "Hello, Filesystem World!" << std::endl;
    (gdb) s
    _ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5Kc (__out=@0x21058, 
        __s=0x10d68 "Hello, Filesystem World!") at std_ostream.h:635
    Line number 635 out of range; std_ostream.h has 288 lines.
    (gdb) <CR>
    _ZNSo6sentryC1ERSo (this=0xffbef848, __os=@0x21058) at ostream.tcc:39
    39          : _M_ok(__os.good()), _M_os(__os)
    (gdb) 

std_ostream.h does an #include of ostream.tcc; both files are mentioned
above.  The line numbers are way way off for ostream.tcc though.  I suspect
that's a compiler problem, but walking through other header files which
do the same thing hasn't been a problem with this build.

If I can get the demangling thing beat, that'd be nice.  Anybody know
what's doing this?


Phil

-- 
pedwards at disaster dot jaj dot com  |  pme at sources dot redhat dot com
devphil at several other less interesting addresses in various dot domains
The gods do not protect fools.  Fools are protected by more capable fools.

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