mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-26 13:56:22 +08:00
gdbsupport: make gdb_assert_not_reached accept a format string
Change gdb_assert_not_reached to accept a format string plus corresponding arguments. This allows giving more precise messages. Because the format string passed by the caller is prepended with a "%s:" to add the function name, the callers can no longer pass a translated string (`_(...)`). Make the gdb_assert_not_reached include the _(), just like the gdb_assert_fail macro just above. Change-Id: Id0cfda5a57979df6cdaacaba0d55dd91ae9efee7
This commit is contained in:
@ -364,7 +364,7 @@ symbol_read_needs (struct symbol *sym)
|
||||
/* All cases listed explicitly so that gcc -Wall will detect it if
|
||||
we failed to consider one. */
|
||||
case LOC_COMPUTED:
|
||||
gdb_assert_not_reached (_("LOC_COMPUTED variable missing a method"));
|
||||
gdb_assert_not_reached ("LOC_COMPUTED variable missing a method");
|
||||
|
||||
case LOC_REGISTER:
|
||||
case LOC_ARG:
|
||||
@ -744,7 +744,7 @@ language_defn::read_var_value (struct symbol *var,
|
||||
break;
|
||||
|
||||
case LOC_COMPUTED:
|
||||
gdb_assert_not_reached (_("LOC_COMPUTED variable missing a method"));
|
||||
gdb_assert_not_reached ("LOC_COMPUTED variable missing a method");
|
||||
|
||||
case LOC_UNRESOLVED:
|
||||
{
|
||||
|
Reference in New Issue
Block a user