summaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.mi
diff options
context:
space:
mode:
authorLuis Machado <luisgpm@br.ibm.com>2013-04-18 10:08:08 +0000
committerLuis Machado <luisgpm@br.ibm.com>2013-04-18 10:08:08 +0000
commit254638dfadb925d3d1fd55f019841d5c6556e752 (patch)
tree2975348a2d2803fd4a2294c533df14dbeb68c628 /gdb/testsuite/gdb.mi
parent45140821a713d7b1ef8cb38c737591abfaaff596 (diff)
downloadgdb-254638dfadb925d3d1fd55f019841d5c6556e752.tar.gz
* gdb.mi/mi-var-create-rtti.exp: Create a variable of
type void *.
Diffstat (limited to 'gdb/testsuite/gdb.mi')
-rw-r--r--gdb/testsuite/gdb.mi/mi-var-create-rtti.exp6
1 files changed, 4 insertions, 2 deletions
diff --git a/gdb/testsuite/gdb.mi/mi-var-create-rtti.exp b/gdb/testsuite/gdb.mi/mi-var-create-rtti.exp
index da3cf1b39ef..f991951254a 100644
--- a/gdb/testsuite/gdb.mi/mi-var-create-rtti.exp
+++ b/gdb/testsuite/gdb.mi/mi-var-create-rtti.exp
@@ -45,8 +45,10 @@ if ![mi_run_to_main] {
# Enable "print object"
mi_gdb_test "-gdb-set print object on" ".*"
-# Test creating a variable for $sp
-mi_gdb_test "-var-create sp1 * \$sp" \
+# Test creating a variable for $sp.
+# We use a explicit cast to (void *) as that is the
+# type that caused the bug this testcase is testing for.
+mi_gdb_test "-var-create sp1 * ((void*)\$sp)" \
"\\^done,name=\"sp1\",numchild=\"0\",value=\"$hex\",type=\"void \\*\",has_more=\"0\"" \
"-var-create sp1 * \$sp"
gdb_exit