aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.base
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2012-11-20 21:02:36 +0000
committerMike Frysinger <vapier@gentoo.org>2012-11-20 21:02:36 +0000
commitace21957447369d273622e8869f1183549cded3d (patch)
treee1b60584fd3f56030179cad26cfc61c417133efe /gdb/testsuite/gdb.base
parentec6632d76b88e151af88bd22fdb310e9dcbb93f5 (diff)
downloadfsf-binutils-gdb-ace21957447369d273622e8869f1183549cded3d.zip
fsf-binutils-gdb-ace21957447369d273622e8869f1183549cded3d.tar.gz
fsf-binutils-gdb-ace21957447369d273622e8869f1183549cded3d.tar.bz2
gdb: include help aliases in help command completion
There are a bunch of aliases that get used with help, but the current command completion logic does not include those when doing completions. Since the framework is already mostly in place, extend complete_on_cmdlist slightly to pass down the ignore_help_classes flag like is done with the existing lookup command logic. Now you can do: (gdb) help use<tab> and get back: (gdb) help user-defined Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'gdb/testsuite/gdb.base')
-rw-r--r--gdb/testsuite/gdb.base/completion.exp13
1 files changed, 13 insertions, 0 deletions
diff --git a/gdb/testsuite/gdb.base/completion.exp b/gdb/testsuite/gdb.base/completion.exp
index 8b1facb..80f7032 100644
--- a/gdb/testsuite/gdb.base/completion.exp
+++ b/gdb/testsuite/gdb.base/completion.exp
@@ -389,6 +389,19 @@ gdb_test_multiple "" "$test" {
}
}
+set test "complete help aliases"
+send_gdb "help user-define\t"
+gdb_test_multiple "" "$test" {
+ -re "^help user-defined $" {
+ send_gdb "\n"
+ gdb_test_multiple "" "$test" {
+ -re "$gdb_prompt $" {
+ pass "$test"
+ }
+ }
+ }
+}
+
# These tests used to try completing the shorter "p b-a".
# Unfortunately, on some systems, there are .o files in system