aboutsummaryrefslogtreecommitdiff
path: root/gdb/cli/cli-decode.h
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>2008-12-10 01:05:16 +0000
committerTom Tromey <tromey@redhat.com>2008-12-10 01:05:16 +0000
commitb05dcbb7f97fb8e8b1449a6bde96761b3cb3e39b (patch)
tree731f71fa9e267810d8f92e632d629c2d384460a8 /gdb/cli/cli-decode.h
parent667f3338da4e4616a2e7d9085a02520a8da98c7f (diff)
downloadgdb-b05dcbb7f97fb8e8b1449a6bde96761b3cb3e39b.zip
gdb-b05dcbb7f97fb8e8b1449a6bde96761b3cb3e39b.tar.gz
gdb-b05dcbb7f97fb8e8b1449a6bde96761b3cb3e39b.tar.bz2
gdb
PR gdb/1815: * cli/cli-decode.c (delete_cmd): Forward declare. (delete_cmd): Now static. Change return type. Remove command from alias chain. Rewrite. (add_cmd): Initialize new fields. Update cmd_pointer on all aliases. (add_alias_cmd): Put command on alias chain. * command.h (delete_cmd): Don't declare. * cli/cli-decode.h (delete_cmd): Don't declare. (struct cmd_list_element) <aliases, alias_chain>: New fields. gdb/testsuite * gdb.base/commands.exp (redefine_backtrace_test): New proc. Call it.
Diffstat (limited to 'gdb/cli/cli-decode.h')
-rw-r--r--gdb/cli/cli-decode.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/gdb/cli/cli-decode.h b/gdb/cli/cli-decode.h
index 4e2dbc1..9d27f0f 100644
--- a/gdb/cli/cli-decode.h
+++ b/gdb/cli/cli-decode.h
@@ -197,6 +197,12 @@ struct cmd_list_element
/* Pointer to command that is aliased by this one, so the
aliased command can be located in case it has been hooked. */
struct cmd_list_element *cmd_pointer;
+
+ /* Start of a linked list of all aliases of this command. */
+ struct cmd_list_element *aliases;
+
+ /* Link pointer for aliases on an alias list. */
+ struct cmd_list_element *alias_chain;
};
/* API to the manipulation of command lists. */
@@ -290,8 +296,6 @@ extern char **complete_on_cmdlist (struct cmd_list_element *, char *, char *);
extern char **complete_on_enum (const char *enumlist[], char *, char *);
-extern void delete_cmd (char *, struct cmd_list_element **);
-
extern void help_cmd_list (struct cmd_list_element *, enum command_class,
char *, int, struct ui_file *);