aboutsummaryrefslogtreecommitdiff
path: root/gdb/command.h
diff options
context:
space:
mode:
authorSimon Marchi <simon.marchi@polymtl.ca>2021-06-25 21:38:25 -0400
committerSimon Marchi <simon.marchi@polymtl.ca>2021-06-25 21:39:26 -0400
commit4c0ba02a749d84a7e569e010fca9f640c30d17df (patch)
treedb5935ef09b75752a45b41f724d63e0c1c7d6c69 /gdb/command.h
parentd6ff04a343f97026f7d23bb036e0f858b21f3bfd (diff)
downloadgdb-4c0ba02a749d84a7e569e010fca9f640c30d17df.zip
gdb-4c0ba02a749d84a7e569e010fca9f640c30d17df.tar.gz
gdb-4c0ba02a749d84a7e569e010fca9f640c30d17df.tar.bz2
gdb: remove context parameter from add_setshow_enum_cmd
I propose removing the context parameter from add_setshow_enum_cmd. It was useful before add_setshow_enum_cmd returned both created commands, as the caller couldn't easily set the context itself. But now, I think it's fine to just let the caller do it. gdb/ChangeLog: * command.h (add_setshow_enum_cmd): Remove context parameter. * cli/cli-decode.c (add_setshow_enum_cmd): Likewise, and don't set context. * cli/cli-style.c (cli_style_option::add_setshow_commands): Set context here. Change-Id: I377c4e6820ec9d5069492ed28f4cba342ce1336e
Diffstat (limited to 'gdb/command.h')
-rw-r--r--gdb/command.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/command.h b/gdb/command.h
index 9413a50..711cbdc 100644
--- a/gdb/command.h
+++ b/gdb/command.h
@@ -403,7 +403,7 @@ extern set_show_commands add_setshow_enum_cmd
const char **var, const char *set_doc, const char *show_doc,
const char *help_doc, cmd_const_sfunc_ftype *set_func,
show_value_ftype *show_func, cmd_list_element **set_list,
- cmd_list_element **show_list, void *context = nullptr);
+ cmd_list_element **show_list);
extern set_show_commands add_setshow_auto_boolean_cmd
(const char *name, command_class theclass, auto_boolean *var,