| Index: gdb/testsuite/gdb.cp/cplabel.exp
|
| diff --git a/gdb/testsuite/gdb.cp/typedef-operator.exp b/gdb/testsuite/gdb.cp/cplabel.exp
|
| similarity index 58%
|
| copy from gdb/testsuite/gdb.cp/typedef-operator.exp
|
| copy to gdb/testsuite/gdb.cp/cplabel.exp
|
| index 1ec6af76cd32e04b764cb0adbce323d3e68b6417..41a91960cd72b546355f7635ceb46b5f21002003 100644
|
| --- a/gdb/testsuite/gdb.cp/typedef-operator.exp
|
| +++ b/gdb/testsuite/gdb.cp/cplabel.exp
|
| @@ -1,5 +1,5 @@
|
| -# Copyright 2011-2012 Free Software Foundation, Inc.
|
| -#
|
| +# Copyright 2012 Free Software Foundation, Inc.
|
| +
|
| # This program is free software; you can redistribute it and/or modify
|
| # it under the terms of the GNU General Public License as published by
|
| # the Free Software Foundation; either version 3 of the License, or
|
| @@ -13,21 +13,28 @@
|
| # You should have received a copy of the GNU General Public License
|
| # along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
| -# This file is part of the gdb testsuite.
|
| +# Tests for breakpoint on labels in methods.
|
|
|
| if {[skip_cplus_tests]} { continue }
|
|
|
| -set testfile "typedef-operator"
|
| -if [prepare_for_testing $testfile $testfile $testfile.cc {c++ debug}] {
|
| +standard_testfile .cc
|
| +
|
| +if {[prepare_for_testing "$testfile.exp" $testfile $srcfile {c++ debug}]} {
|
| return -1
|
| }
|
|
|
| -gdb_test_no_output "set language c++"
|
| -
|
| -gdb_test "p *u" {You can't do that without a process to debug.} "test crash"
|
| -
|
| -if ![runto_main] {
|
| +if {![runto_main]} {
|
| + untested "could not run to main"
|
| return -1
|
| }
|
|
|
| -gdb_test "p *v" " = 42" "test typedef"
|
| +set methods {"bar" "baz"}
|
| +set labels {"to_the_top" "get_out_of_here"}
|
| +
|
| +foreach m $methods {
|
| + foreach l $labels {
|
| + set line [gdb_get_line_number "$m:$l"]
|
| + gdb_test "break foo::$m:$l" \
|
| + "Breakpoint $decimal at $hex: file .*/$srcfile, line $line\."
|
| + }
|
| +}
|
|
|