I've loaded up two versions of a C++ library in gdb, opened up the built-in Python interpreter, and run
import gdb
gdb.lookup_type('Foo<Bar>')
In one version, it works just fine. However, in the other, I get
gdb.error: No type named Foo<Bar>.
I've confirmed that both the Foo
template as well as the Bar
class still exist in the latter library's source. What could explain the failure to look up the type? Does Foo<Bar>
have to "exist" in the source in that combination for the type to show up under gdb?
Running file
on the libraries produces
libfoo.so: ELF 64-bit LSB shared object, ARM aarch64, version 1 (SYSV), dynamically linked, BuildId[xxHash]=..., with debug_info, not stripped