aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.base/radix.exp
diff options
context:
space:
mode:
authorPedro Alves <palves@redhat.com>2009-01-23 18:47:46 +0000
committerPedro Alves <palves@redhat.com>2009-01-23 18:47:46 +0000
commit1e8fb9762b0d2c468915815f73d2fadb44543be1 (patch)
treee06f47a274d8a332ed81aec3d10e2653b8b9aa7b /gdb/testsuite/gdb.base/radix.exp
parent278df34e1203e781f97b32320094e1831f5f9624 (diff)
downloadfsf-binutils-gdb-1e8fb9762b0d2c468915815f73d2fadb44543be1.zip
fsf-binutils-gdb-1e8fb9762b0d2c468915815f73d2fadb44543be1.tar.gz
fsf-binutils-gdb-1e8fb9762b0d2c468915815f73d2fadb44543be1.tar.bz2
2009-01-23 Pedro Alves <pedro@codesourcery.com>
* cli/cli-decode.c (add_setshow_zuinteger_cmd): New. * cli/cli-setshow.c (do_setshow_command): Handle it. * command.h (enum var_types): Add var_zuinteger. (add_setshow_zuinteger_cmd): Declare. * valprint.c (_initialize_valprint): Change the set input-radix and set output-radix commands to zuinteger type. 2009-01-23 Pedro Alves <pedro@codesourcery.com> * gdb.base/radix.exp: Add tests to ensure that that set input-radix 0 and set output-radix 0 are really rejected.
Diffstat (limited to 'gdb/testsuite/gdb.base/radix.exp')
-rw-r--r--gdb/testsuite/gdb.base/radix.exp17
1 files changed, 15 insertions, 2 deletions
diff --git a/gdb/testsuite/gdb.base/radix.exp b/gdb/testsuite/gdb.base/radix.exp
index 172e40f..750fd23 100644
--- a/gdb/testsuite/gdb.base/radix.exp
+++ b/gdb/testsuite/gdb.base/radix.exp
@@ -162,19 +162,32 @@ gdb_test "set radix" \
"Input and output radices now set to decimal 10, hex a, octal 12\." \
"Reset radices"
+gdb_test "set input-radix 0" \
+ "Nonsense input radix ``decimal 0''; input radix unchanged\\." \
+ "Reject input-radix 0"
+gdb_test "show input-radix" \
+ "Default input radix for entering numbers is 10\\." \
+ "Input radix unchanged after rejecting 0"
+
gdb_test "set input-radix 1" \
"Nonsense input radix ``decimal 1''; input radix unchanged\\." \
"Reject input-radix 1"
gdb_test "show input-radix" \
"Default input radix for entering numbers is 10\\." \
- "Input radix unchanged after rejection"
+ "Input radix unchanged after rejecting 1"
+gdb_test "set output-radix 0" \
+ "Unsupported output radix ``decimal 0''; output radix unchanged\\." \
+ "Reject output-radix 0"
+gdb_test "show output-radix" \
+ "Default output radix for printing of values is 10\\." \
+ "Output radix unchanged after rejecting 0"
gdb_test "set output-radix 1" \
"Unsupported output radix ``decimal 1''; output radix unchanged\\." \
"Reject output-radix 1"
gdb_test "show output-radix" \
"Default output radix for printing of values is 10\\." \
- "Output radix unchanged after rejection"
+ "Output radix unchanged after rejecting 1"
gdb_test "set radix 7" \
"Unsupported output radix ``decimal 7''; output radix unchanged\\." \