[RFA 03/67] Constify not_just_help_class_command

Tom Tromey
2017-09-21T05:12:52Z

* command.h (not_just_help_class_command): Update.
* cli/cli-decode.h (not_just_help_class_command): Update.
* cli/cli-decode.c (not_just_help_class_command): Constify.
---
gdb/ChangeLog | 6 ++++++
gdb/cli/cli-decode.c | 2 +-
gdb/cli/cli-decode.h | 2 +-
gdb/command.h | 2 +-
4 files changed, 9 insertions(+), 3 deletions(-)

diff --git a/gdb/cli/cli-decode.c b/gdb/cli/cli-decode.c
index 55d4124..577fea9 100644
--- a/gdb/cli/cli-decode.c
+++ b/gdb/cli/cli-decode.c
@@ -440,7 +440,7 @@ add_abbrev_prefix_cmd (const char *name, enum command_class theclass,

/* This is an empty "cfunc". */
void
-not_just_help_class_command (char *args, int from_tty)
+not_just_help_class_command (const char *args, int from_tty)
{
}

diff --git a/gdb/cli/cli-decode.h b/gdb/cli/cli-decode.h
index 691bfe3..76f3ca9 100644
--- a/gdb/cli/cli-decode.h
+++ b/gdb/cli/cli-decode.h
@@ -228,7 +228,7 @@ extern void apropos_cmd (struct ui_file *, struct cmd_list_element *,
function field NULL, the command is interpreted as a help topic, or
as a class of commands. */

-extern void not_just_help_class_command (char *arg, int from_tty);
+extern void not_just_help_class_command (const char *arg, int from_tty);

/* Exported to cli/cli-setshow.c */

diff --git a/gdb/command.h b/gdb/command.h
index b6c4091..6d9bac8 100644
--- a/gdb/command.h
+++ b/gdb/command.h
@@ -452,7 +452,7 @@ extern scoped_restore_tmpl<int> prevent_dont_repeat (void);
function field NULL, the command is interpreted as a help topic, or
as a class of commands. */

-extern void not_just_help_class_command (char *, int);
+extern void not_just_help_class_command (const char *, int);

/* Check function pointer. */
extern int cmd_func_p (struct cmd_list_element *cmd);
--
2.9.4