diff options
author | Philippe Waroquiers <philippe.waroquiers@skynet.be> | 2020-05-10 21:36:14 +0200 |
---|---|---|
committer | Philippe Waroquiers <philippe.waroquiers@skynet.be> | 2020-05-15 22:17:46 +0200 |
commit | 57b4f16e494d8abdeb0748c69e72f911b3525b44 (patch) | |
tree | dfc66c3910d9bce236f778816771264549e74372 /gdb/reverse.c | |
parent | 7c05caf72d31d7382819f1113fdcf13c45729a8d (diff) | |
download | gdb-57b4f16e494d8abdeb0748c69e72f911b3525b44.zip gdb-57b4f16e494d8abdeb0748c69e72f911b3525b44.tar.gz gdb-57b4f16e494d8abdeb0748c69e72f911b3525b44.tar.bz2 |
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 <philippe.waroquiers@skynet.be>
* 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 <philippe.waroquiers@skynet.be>
* gdb.base/alias.exp: Verify 'help aliases' shows user defined aliases.
Diffstat (limited to 'gdb/reverse.c')
-rw-r--r-- | gdb/reverse.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/gdb/reverse.c b/gdb/reverse.c index 1ccb9d2..583e0d0 100644 --- a/gdb/reverse.c +++ b/gdb/reverse.c @@ -330,7 +330,7 @@ _initialize_reverse () Step program backward until it reaches the beginning of another source line.\n\ Argument N means do this N times (or till program stops for another reason).") ); - add_com_alias ("rs", "reverse-step", class_alias, 1); + add_com_alias ("rs", "reverse-step", class_run, 1); add_com ("reverse-next", class_run, reverse_next, _("\ Step program backward, proceeding through subroutine calls.\n\ @@ -338,26 +338,26 @@ Like the \"reverse-step\" command as long as subroutine calls do not happen;\n\ when they do, the call is treated as one instruction.\n\ Argument N means do this N times (or till program stops for another reason).") ); - add_com_alias ("rn", "reverse-next", class_alias, 1); + add_com_alias ("rn", "reverse-next", class_run, 1); add_com ("reverse-stepi", class_run, reverse_stepi, _("\ Step backward exactly one instruction.\n\ Argument N means do this N times (or till program stops for another reason).") ); - add_com_alias ("rsi", "reverse-stepi", class_alias, 0); + add_com_alias ("rsi", "reverse-stepi", class_run, 0); add_com ("reverse-nexti", class_run, reverse_nexti, _("\ Step backward one instruction, but proceed through called subroutines.\n\ Argument N means do this N times (or till program stops for another reason).") ); - add_com_alias ("rni", "reverse-nexti", class_alias, 0); + add_com_alias ("rni", "reverse-nexti", class_run, 0); add_com ("reverse-continue", class_run, reverse_continue, _("\ Continue program being debugged but run it in reverse.\n\ If proceeding from breakpoint, a number N may be used as an argument,\n\ which means to set the ignore count of that breakpoint to N - 1 (so that\n\ the breakpoint won't break until the Nth time it is reached).")); - add_com_alias ("rc", "reverse-continue", class_alias, 0); + add_com_alias ("rc", "reverse-continue", class_run, 0); add_com ("reverse-finish", class_run, reverse_finish, _("\ Execute backward until just before selected stack frame is called.")); |