aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/lib
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>2012-11-12 17:08:09 +0000
committerTom Tromey <tromey@redhat.com>2012-11-12 17:08:09 +0000
commitb3720c3afd7fc68cf30b2ce40a8f0ccddc8f5069 (patch)
tree05f57e6a7ea6dfbc54a07c3feaf8da1f71166150 /gdb/testsuite/lib
parent8f5846c8afb497bf9e6576de75b02a0b1fd03643 (diff)
downloadgdb-b3720c3afd7fc68cf30b2ce40a8f0ccddc8f5069.zip
gdb-b3720c3afd7fc68cf30b2ce40a8f0ccddc8f5069.tar.gz
gdb-b3720c3afd7fc68cf30b2ce40a8f0ccddc8f5069.tar.bz2
* gdb.cp/classes.exp (test_ptype_class_objects): Remove
"ptype" from calls to cp_test_ptype_class. (test_enums): Likewise. * gdb.cp/derivation.exp: Remove "ptype" from calls to cp_test_ptype_class. * gdb.cp/inherit.exp (test_ptype_si): Remove "ptype" from calls to cp_test_ptype_class. (test_ptype_mi, test_ptype_vi, test_ptype_mvi): Likewise. * gdb.cp/virtfunc.exp (test_ptype_of_classes): Remove "ptype" from calls to cp_test_ptype_class. * lib/cp-support.exp (cp_test_ptype_class): Supply "ptype" command here. Change "in_command" argument to "in_exp".
Diffstat (limited to 'gdb/testsuite/lib')
-rw-r--r--gdb/testsuite/lib/cp-support.exp11
1 files changed, 7 insertions, 4 deletions
diff --git a/gdb/testsuite/lib/cp-support.exp b/gdb/testsuite/lib/cp-support.exp
index 467a25e..1414ffc 100644
--- a/gdb/testsuite/lib/cp-support.exp
+++ b/gdb/testsuite/lib/cp-support.exp
@@ -45,9 +45,10 @@ proc cp_check_errata { expected_string actual_string errata_table } {
# each line, matching it to the class description given in the
# parameters.
#
-# IN_COMMAND and IN_TESTNAME are the command and testname for
+# IN_EXP is the expression to use; the appropriate "ptype" invocation
+# is prepended to it. IN_TESTNAME is the testname for
# gdb_test_multiple. If IN_TESTNAME is the empty string, then it
-# defaults to IN_COMMAND.
+# defaults to "ptype IN_EXP".
#
# IN_KEY is "class" or "struct". For now, I ignore it, and allow either
# "class" or "struct" in the output, as long as the access specifiers all
@@ -177,13 +178,15 @@ proc cp_check_errata { expected_string actual_string errata_table } {
#
# -- chastain 2004-08-07
-proc cp_test_ptype_class { in_command in_testname in_key in_tag in_class_table { in_tail "" } { in_errata_table { } } } {
+proc cp_test_ptype_class { in_exp in_testname in_key in_tag in_class_table { in_tail "" } { in_errata_table { } } } {
global gdb_prompt
set wsopt "\[\r\n\t \]*"
# The test name defaults to the command.
- if { "$in_testname" == "" } then { set in_testname "$in_command" }
+ if { "$in_testname" == "" } then { set in_testname "ptype $in_exp" }
+
+ set in_command "ptype $in_exp"
# Save class tables in a history array for reuse.