From 57b4f16e494d8abdeb0748c69e72f911b3525b44 Mon Sep 17 00:00:00 2001 From: Philippe Waroquiers Date: Sun, 10 May 2020 21:36:14 +0200 Subject: Ensure class_alias is only used for user-defined aliases. This commit finally does the (small) change that started this patch series. It ensures that the class_alias is only used for user-defined aliases. So, the few GDB pre-defined aliases that were using the 'class_alias' class are now using a real help class, typically the class of the aliased command. gdb/ChangeLog 2020-05-15 Philippe Waroquiers * command.h (enum command_class): Improve comments, document that class_alias is for user-defined aliases, give the class name for each class, remove unused class_xdb. * cli/cli-decode.c (add_com_alias): Document THECLASS intended usage. * breakpoint.c (_initialize_breakpoint): Replace class_alias by a precise class. * infcmd.c (_initialize_infcmd): Likewise. * reverse.c (_initialize_reverse): Likewise. * stack.c (_initialize_stack): Likewise. * symfile.c (_initialize_symfile): Likewise. * tracepoint.c (_initialize_tracepoint): Likewise. gdb/testsuite/ChangeLog 2020-05-15 Philippe Waroquiers * gdb.base/alias.exp: Verify 'help aliases' shows user defined aliases. --- gdb/stack.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gdb/stack.c') diff --git a/gdb/stack.c b/gdb/stack.c index f67a151..d7e2120 100644 --- a/gdb/stack.c +++ b/gdb/stack.c @@ -3485,7 +3485,7 @@ With a negative COUNT, print outermost -COUNT frames."), add_com_alias ("bt", "backtrace", class_stack, 0); - add_com_alias ("where", "backtrace", class_alias, 0); + add_com_alias ("where", "backtrace", class_stack, 0); add_info ("stack", backtrace_command, _("Backtrace of the stack, or innermost COUNT frames.")); add_info_alias ("s", "stack", 1); -- cgit v1.1