This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: ver_test_8_2.so
From: "Maciej W. Rozycki" <macro@linux-mips.org>
Date: Tue, 20 May 2008 23:15:47 +0100 (BST)
> On Tue, 20 May 2008, David Miller wrote:
>
> > For example, if I wanted to set a breakpoint on:
> >
> > Target_sparc<32, true>::Scan::local()
> >
> > how might I specify that to gdb?
>
> Hmm, how about:
>
> (gdb) break Target_sparc<32, true>::Scan::local
gdb 6.8.50-20080411-cvs
(gdb) break Target_sparc<32, true>::Scan::local
Can't find member of namespace, class, struct, or union named "Target_sparc<32, true>::Scan::local"
Hint: try 'Target_sparc<32, true>::Scan::local<TAB> or 'Target_sparc<32, true>::Scan::local<ESC-?>
(Note leading single quote.)
(gdb)
> GDB is supposed to be able to place breakpoints on templated functions and
> there are some cases in the test suite to cover it. Perhaps you have
> found a bug in GDB or elsewhere (DWARF-2?)...
I mentioned the anonymous namespace surrounding all the code in sparc.cc,
because I think that's relevant to the problem. And sure enough it is.
If I remove the "namespace {" and closing "}" from sparc.cc, the break
command above works properly.
I've tried things like prefixing the name with "::" and whatnot,
nothing works.