aboutsummaryrefslogtreecommitdiff
path: root/gdb/ax-gdb.c
diff options
context:
space:
mode:
authorSimon Marchi <simon.marchi@polymtl.ca>2021-11-17 13:44:01 -0500
committerSimon Marchi <simon.marchi@polymtl.ca>2021-11-18 11:29:19 -0500
commit557b4d7650ffa3cd6dbfb8a56c830a1d45562d19 (patch)
tree0c08f5fc48886db33c57cb42bfaa1d0fc80640cc /gdb/ax-gdb.c
parentab198279120fe7937c0970a8bb881922726678f9 (diff)
downloadfsf-binutils-gdb-557b4d7650ffa3cd6dbfb8a56c830a1d45562d19.zip
fsf-binutils-gdb-557b4d7650ffa3cd6dbfb8a56c830a1d45562d19.tar.gz
fsf-binutils-gdb-557b4d7650ffa3cd6dbfb8a56c830a1d45562d19.tar.bz2
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
Diffstat (limited to 'gdb/ax-gdb.c')
-rw-r--r--gdb/ax-gdb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/ax-gdb.c b/gdb/ax-gdb.c
index 8e391a0..67d4db3 100644
--- a/gdb/ax-gdb.c
+++ b/gdb/ax-gdb.c
@@ -609,7 +609,7 @@ gen_var_ref (struct agent_expr *ax, struct axs_value *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_OPTIMIZED_OUT:
/* Flag this, but don't say anything; leave it up to callers to