There is gdb.lookup_type("SomeType") in GDB python API as listed blow, but I cannot find a way to get the source file and line number where the type is defined, much like what the GDB command info types ^SomeType$ does. Is it possible via GDB python API without invoking into the info types command?
https://sourceware.org/gdb/onlinedocs/gdb/Types-In-Python.html#Types-In-Python
gdb.lookup_static_symbol("SomeType"), you should get a gdb.Symbol of the type, withsymtabandlinefields.gdb.lookup_static_symbol("SomeType")seems working, thanks.