diff options
author | Andrew Burgess <aburgess@redhat.com> | 2022-12-02 12:10:10 +0000 |
---|---|---|
committer | Andrew Burgess <aburgess@redhat.com> | 2022-12-14 10:56:47 +0000 |
commit | b1e678d920e4468cfd69a40560ee24834f6bdce4 (patch) | |
tree | ae0cbecef648906b195ee5a71f93e2aeade38f69 /gdb/language.c | |
parent | 9f50fe0835850645bd8ea9bb1efe1fe6c48dfb12 (diff) | |
download | fsf-binutils-gdb-b1e678d920e4468cfd69a40560ee24834f6bdce4.zip fsf-binutils-gdb-b1e678d920e4468cfd69a40560ee24834f6bdce4.tar.gz fsf-binutils-gdb-b1e678d920e4468cfd69a40560ee24834f6bdce4.tar.bz2 |
gdb: convert 'set debug symbol-lookup' to new debug printing scheme
Convert the implementation of 'set debug symbol-lookup' to the new
debug printing scheme.
In a few places I've updated the debug output to remove places where
the printed debug message included the function name, the new debug
scheme already adds that, but I haven't done all the possible updates.
Diffstat (limited to 'gdb/language.c')
-rw-r--r-- | gdb/language.c | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/gdb/language.c b/gdb/language.c index 3962ee8..5083a86 100644 --- a/gdb/language.c +++ b/gdb/language.c @@ -1077,17 +1077,15 @@ language_lookup_primitive_type_as_symbol (const struct language_defn *la, struct language_gdbarch *ld = get_language_gdbarch (gdbarch); struct language_arch_info *lai = &ld->arch_info[la->la_language]; - if (symbol_lookup_debug) - gdb_printf (gdb_stdlog, - "language_lookup_primitive_type_as_symbol" - " (%s, %s, %s)", - la->name (), host_address_to_string (gdbarch), name); + symbol_lookup_debug_printf + ("language = \"%s\", gdbarch @ %s, type = \"%s\")", + la->name (), host_address_to_string (gdbarch), name); struct symbol *sym = lai->lookup_primitive_type_as_symbol (name, la->la_language); - if (symbol_lookup_debug) - gdb_printf (gdb_stdlog, " = %s\n", host_address_to_string (sym)); + symbol_lookup_debug_printf ("found symbol @ %s", + host_address_to_string (sym)); /* Note: The result of symbol lookup is normally a symbol *and* the block it was found in. Builtin types don't live in blocks. We *could* give |