2010-01-01 07:32:07 +00:00
# Copyright (C) 1998, 1999, 2001, 2004, 2007, 2008, 2009, 2010
2008-01-01 22:53:26 +00:00
# Free Software Foundation, Inc.
1999-04-16 01:35:26 +00:00
# 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
2007-08-23 18:14:19 +00:00
# the Free Software Foundation; either version 3 of the License, or
1999-04-16 01:35:26 +00:00
# (at your option) any later version.
2007-08-23 18:14:19 +00:00
#
1999-04-16 01:35:26 +00:00
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
2007-08-23 18:14:19 +00:00
#
1999-04-16 01:35:26 +00:00
# You should have received a copy of the GNU General Public License
2007-08-23 18:14:19 +00:00
# along with this program. If not, see <http://www.gnu.org/licenses/>.
1999-04-16 01:35:26 +00:00
# written by Elena Zannoni (ezannoni@cygnus.com)
2001-01-28 23:49:43 +00:00
# modified by Michael Chastain (chastain@redhat.com)
1999-04-16 01:35:26 +00:00
# This file is part of the gdb testsuite
#
# tests for overloaded member functions. Set breakpoints on
# overloaded member functions
#
* gdb.cp/cp-relocate.exp: Remove single-quoting of C++ methods.
* gdb.cp/cplusfuncs.cc (dm_type_short): New function.
(dm_type_long): New function.
(dm_type_unsigned_short): New function.
(dm_type_unsigned_long): New function.
(myint): New typedef.
* gdb.cp/cplusfuncs.exp (probe_demangler): Add tests for short,
long, unsigned shor and long, operator char*, and typedef.
(test_lookup_operator_functions): Add operator char* test.
(test_paddr_operator_functions): Likewise.
(test_paddr_overloaded_functions): Use probe values for
short, long, and unsigned short and long.
(test_paddr_hairy_functions): If the demangler probe detected
gdb type printers, "expect" them. Otherwise "expect" the v2 or v3
demangler.
* gdb.cp/expand-sals.exp: Backtrace may contain class names.
* gdb.cp/member-ptr.exp: Refine expected result for "print pmf"
and "print null_pmf".
Add test "ptype a.*pmf".
* gdb.cp/overload.exp: Allow optional "int" to appear with
"short" and "long".
* gdb.cp/ovldbreak.exp: Use append to construct super-duper
long expect value for men_overload1arg.
Allow "int" to appear with "short" and "long".
When testing "info break", add argument for main (void).
Also allow "int" to appear with "short" and "long".
Ditto with "unsigned" and "long long".
* gdb.java/jmain.exp: Do not enclose methods names in single
quotes.
* gdb.java/jmisc.exp: Likewise.
* gdb.java/jprint.exp: Likewise.
* gdb.python/py-symbol.exp: Update expected "linkage_name" value.
From Jan Kratochvil <jan.kratochvil@redhat.com>:
* gdb.cp/exception.exp (backtrace after first throw)
(backtrace after second throw): Allow a namespace before __cxa_throw.
(backtrace after first catch, backtrace after second catch): Allow
a namespace before __cxa_begin_catch.
* gdb.cp/cpexprs.exp: New file.
* gdb.cp/cpexprs.cc: New file.
From Daniel Jacobowitz <dan@codesourcery.com>
* gdb.cp/cpexprs.exp (escape): Delete. Change all callers
to use string_to_regexp.
(ctor, dtor): New functions. Use them to match constructor
and destructor function types.
(Top level): Use runto_main.
2010-03-09 18:08:05 +00:00
global timeout
set timeout 15
1999-04-16 01:35:26 +00:00
if $tracelevel then {
strace $tracelevel
}
#
# test running programs
#
1999-09-09 00:02:17 +00:00
if { [skip_cplus_tests] } { continue }
1999-04-16 01:35:26 +00:00
set testfile "ovldbreak"
set srcfile ${testfile}.cc
set binfile ${objdir}/${subdir}/${testfile}
if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug c++}] != "" } {
2006-08-10 05:27:22 +00:00
untested ovldbreak.exp
return -1
1999-04-16 01:35:26 +00:00
}
gdb_exit
gdb_start
gdb_reinitialize_dir $srcdir/$subdir
gdb_load ${binfile}
# set it up at a breakpoint so we can play with the variable values
#
if ![runto_main] then {
perror "couldn't run to breakpoint"
continue
}
2001-01-28 23:49:43 +00:00
# When I ask gdb to set a breakpoint on an overloaded function,
# gdb gives me a choice menu. I might get stuck in that choice menu
# (for example, if C++ name mangling is not working properly).
#
# This procedure issues a command that works at either the menu
# prompt or the command prompt to get back to the command prompt.
#
# Note that an empty line won't do it (it means 'repeat the previous command'
# at top level). A line with a single space in it works nicely.
1999-04-16 01:35:26 +00:00
2001-01-28 23:49:43 +00:00
proc take_gdb_out_of_choice_menu {} {
global gdb_prompt
2010-06-01 18:18:35 +00:00
gdb_test_multiple " " " " {
2001-01-28 23:49:43 +00:00
-re ".*$gdb_prompt $" {
}
timeout {
perror "could not resynchronize to command prompt (timeout)"
continue
}
}
}
1999-04-16 01:35:26 +00:00
2001-01-28 23:49:43 +00:00
# This procedure sets an overloaded breakpoint.
# When I ask for such a breakpoint, gdb gives me a menu of 'cancel' 'all'
# and a bunch of choices. I then choose from that menu by number.
1999-04-16 01:35:26 +00:00
2001-01-28 23:49:43 +00:00
proc set_bp_overloaded {name expectedmenu mychoice bpnumber linenumber} {
global gdb_prompt hex srcfile
1999-04-16 01:35:26 +00:00
2001-01-28 23:49:43 +00:00
# Get into the overload menu.
send_gdb "break $name\n"
gdb_expect {
-re "$expectedmenu" {
pass "bp menu for $name choice $mychoice"
1999-04-16 01:35:26 +00:00
2001-01-28 23:49:43 +00:00
# Choose my choice.
send_gdb "$mychoice\n"
1999-04-16 01:35:26 +00:00
gdb_expect {
2001-01-28 23:49:43 +00:00
-re "Breakpoint $bpnumber at $hex: file.*$srcfile, line $linenumber.\r\n$gdb_prompt $" {
pass "set bp $bpnumber on $name $mychoice line $linenumber"
}
-re ".*$gdb_prompt $" {
fail "set bp $bpnumber on $name $mychoice line $linenumber (bad bp)"
}
timeout {
fail "set bp $bpnumber on $name $mychoice line $linenumber (timeout)"
take_gdb_out_of_choice_menu
}
}
}
-re ".*\r\n> " {
fail "bp menu for $name choice $mychoice (bad menu)"
take_gdb_out_of_choice_menu
}
-re ".*$gdb_prompt $" {
fail "bp menu for $name choice $mychoice (no menu)"
}
timeout {
fail "bp menu for $name choice $mychoice (timeout)"
take_gdb_out_of_choice_menu
}
}
}
1999-04-16 01:35:26 +00:00
2001-01-28 23:49:43 +00:00
# This is the expected menu for overload1arg.
* gdb.cp/cp-relocate.exp: Remove single-quoting of C++ methods.
* gdb.cp/cplusfuncs.cc (dm_type_short): New function.
(dm_type_long): New function.
(dm_type_unsigned_short): New function.
(dm_type_unsigned_long): New function.
(myint): New typedef.
* gdb.cp/cplusfuncs.exp (probe_demangler): Add tests for short,
long, unsigned shor and long, operator char*, and typedef.
(test_lookup_operator_functions): Add operator char* test.
(test_paddr_operator_functions): Likewise.
(test_paddr_overloaded_functions): Use probe values for
short, long, and unsigned short and long.
(test_paddr_hairy_functions): If the demangler probe detected
gdb type printers, "expect" them. Otherwise "expect" the v2 or v3
demangler.
* gdb.cp/expand-sals.exp: Backtrace may contain class names.
* gdb.cp/member-ptr.exp: Refine expected result for "print pmf"
and "print null_pmf".
Add test "ptype a.*pmf".
* gdb.cp/overload.exp: Allow optional "int" to appear with
"short" and "long".
* gdb.cp/ovldbreak.exp: Use append to construct super-duper
long expect value for men_overload1arg.
Allow "int" to appear with "short" and "long".
When testing "info break", add argument for main (void).
Also allow "int" to appear with "short" and "long".
Ditto with "unsigned" and "long long".
* gdb.java/jmain.exp: Do not enclose methods names in single
quotes.
* gdb.java/jmisc.exp: Likewise.
* gdb.java/jprint.exp: Likewise.
* gdb.python/py-symbol.exp: Update expected "linkage_name" value.
From Jan Kratochvil <jan.kratochvil@redhat.com>:
* gdb.cp/exception.exp (backtrace after first throw)
(backtrace after second throw): Allow a namespace before __cxa_throw.
(backtrace after first catch, backtrace after second catch): Allow
a namespace before __cxa_begin_catch.
* gdb.cp/cpexprs.exp: New file.
* gdb.cp/cpexprs.cc: New file.
From Daniel Jacobowitz <dan@codesourcery.com>
* gdb.cp/cpexprs.exp (escape): Delete. Change all callers
to use string_to_regexp.
(ctor, dtor): New functions. Use them to match constructor
and destructor function types.
(Top level): Use runto_main.
2010-03-09 18:08:05 +00:00
# Note the arg type variations for void and integer types.
2001-01-28 23:49:43 +00:00
# This accommodates different versions of g++.
1999-04-16 01:35:26 +00:00
* gdb.cp/cp-relocate.exp: Remove single-quoting of C++ methods.
* gdb.cp/cplusfuncs.cc (dm_type_short): New function.
(dm_type_long): New function.
(dm_type_unsigned_short): New function.
(dm_type_unsigned_long): New function.
(myint): New typedef.
* gdb.cp/cplusfuncs.exp (probe_demangler): Add tests for short,
long, unsigned shor and long, operator char*, and typedef.
(test_lookup_operator_functions): Add operator char* test.
(test_paddr_operator_functions): Likewise.
(test_paddr_overloaded_functions): Use probe values for
short, long, and unsigned short and long.
(test_paddr_hairy_functions): If the demangler probe detected
gdb type printers, "expect" them. Otherwise "expect" the v2 or v3
demangler.
* gdb.cp/expand-sals.exp: Backtrace may contain class names.
* gdb.cp/member-ptr.exp: Refine expected result for "print pmf"
and "print null_pmf".
Add test "ptype a.*pmf".
* gdb.cp/overload.exp: Allow optional "int" to appear with
"short" and "long".
* gdb.cp/ovldbreak.exp: Use append to construct super-duper
long expect value for men_overload1arg.
Allow "int" to appear with "short" and "long".
When testing "info break", add argument for main (void).
Also allow "int" to appear with "short" and "long".
Ditto with "unsigned" and "long long".
* gdb.java/jmain.exp: Do not enclose methods names in single
quotes.
* gdb.java/jmisc.exp: Likewise.
* gdb.java/jprint.exp: Likewise.
* gdb.python/py-symbol.exp: Update expected "linkage_name" value.
From Jan Kratochvil <jan.kratochvil@redhat.com>:
* gdb.cp/exception.exp (backtrace after first throw)
(backtrace after second throw): Allow a namespace before __cxa_throw.
(backtrace after first catch, backtrace after second catch): Allow
a namespace before __cxa_begin_catch.
* gdb.cp/cpexprs.exp: New file.
* gdb.cp/cpexprs.cc: New file.
From Daniel Jacobowitz <dan@codesourcery.com>
* gdb.cp/cpexprs.exp (escape): Delete. Change all callers
to use string_to_regexp.
(ctor, dtor): New functions. Use them to match constructor
and destructor function types.
(Top level): Use runto_main.
2010-03-09 18:08:05 +00:00
set menu_overload1arg "\\\[0\\\] cancel\r\n"
append menu_overload1arg "\\\[1\\\] all\r\n"
append menu_overload1arg "\\\[2\\\] foo::overload1arg\\(double\\) at.*$srcfile:121\r\n"
append menu_overload1arg "\\\[3\\\] foo::overload1arg\\(float\\) at.*$srcfile:120\r\n"
append menu_overload1arg "\\\[4\\\] foo::overload1arg\\((unsigned long|long unsigned)( int)?\\) at.*$srcfile:119\r\n"
append menu_overload1arg "\\\[5\\\] foo::overload1arg\\(long( int)?\\) at.*$srcfile:118\r\n"
append menu_overload1arg "\\\[6\\\] foo::overload1arg\\((unsigned int|unsigned)\\) at.*$srcfile:117\r\n"
append menu_overload1arg "\\\[7\\\] foo::overload1arg\\(int\\) at.*$srcfile:116\r\n"
append menu_overload1arg "\\\[8\\\] foo::overload1arg\\((unsigned short|short unsigned)( int)?\\) at.*$srcfile:115\r\n"
append menu_overload1arg "\\\[9\\\] foo::overload1arg\\(short( int)?\\) at.*$srcfile:114\r\n"
append menu_overload1arg "\\\[10\\\] foo::overload1arg\\(unsigned char\\) at.*$srcfile:113\r\n"
append menu_overload1arg "\\\[11\\\] foo::overload1arg\\(signed char\\) at.*$srcfile:112\r\n"
append menu_overload1arg "\\\[12\\\] foo::overload1arg\\(char\\) at.*$srcfile:111\r\n"
append menu_overload1arg "\\\[13\\\] foo::overload1arg\\((void|)\\) at.*$srcfile:110\r\n"
append menu_overload1arg "> $"
1999-04-16 01:35:26 +00:00
2008-04-03 21:42:33 +00:00
# Set multiple-symbols to "ask", to allow us to test the use
# of the multiple-choice menu when breaking on an overloaded method.
gdb_test "set multiple-symbols ask" ""
1999-04-16 01:35:26 +00:00
2001-01-28 23:49:43 +00:00
# Set breakpoints on foo::overload1arg, one by one.
1999-04-16 01:35:26 +00:00
2001-01-28 23:49:43 +00:00
set_bp_overloaded "foo::overload1arg" "$menu_overload1arg" 12 2 111
set_bp_overloaded "foo::overload1arg" "$menu_overload1arg" 11 3 112
set_bp_overloaded "foo::overload1arg" "$menu_overload1arg" 10 4 113
set_bp_overloaded "foo::overload1arg" "$menu_overload1arg" 9 5 114
set_bp_overloaded "foo::overload1arg" "$menu_overload1arg" 8 6 115
set_bp_overloaded "foo::overload1arg" "$menu_overload1arg" 7 7 116
set_bp_overloaded "foo::overload1arg" "$menu_overload1arg" 6 8 117
set_bp_overloaded "foo::overload1arg" "$menu_overload1arg" 5 9 118
set_bp_overloaded "foo::overload1arg" "$menu_overload1arg" 4 10 119
set_bp_overloaded "foo::overload1arg" "$menu_overload1arg" 3 11 120
set_bp_overloaded "foo::overload1arg" "$menu_overload1arg" 2 12 121
set_bp_overloaded "foo::overload1arg" "$menu_overload1arg" 13 13 110
1999-04-16 01:35:26 +00:00
2001-01-28 23:49:43 +00:00
# Verify the breakpoints.
1999-04-16 01:35:26 +00:00
gdb_test "info break" \
2008-02-26 08:14:11 +00:00
"Num Type\[\t \]+Disp Enb Address\[\t \]+What.*
* gdb.cp/cp-relocate.exp: Remove single-quoting of C++ methods.
* gdb.cp/cplusfuncs.cc (dm_type_short): New function.
(dm_type_long): New function.
(dm_type_unsigned_short): New function.
(dm_type_unsigned_long): New function.
(myint): New typedef.
* gdb.cp/cplusfuncs.exp (probe_demangler): Add tests for short,
long, unsigned shor and long, operator char*, and typedef.
(test_lookup_operator_functions): Add operator char* test.
(test_paddr_operator_functions): Likewise.
(test_paddr_overloaded_functions): Use probe values for
short, long, and unsigned short and long.
(test_paddr_hairy_functions): If the demangler probe detected
gdb type printers, "expect" them. Otherwise "expect" the v2 or v3
demangler.
* gdb.cp/expand-sals.exp: Backtrace may contain class names.
* gdb.cp/member-ptr.exp: Refine expected result for "print pmf"
and "print null_pmf".
Add test "ptype a.*pmf".
* gdb.cp/overload.exp: Allow optional "int" to appear with
"short" and "long".
* gdb.cp/ovldbreak.exp: Use append to construct super-duper
long expect value for men_overload1arg.
Allow "int" to appear with "short" and "long".
When testing "info break", add argument for main (void).
Also allow "int" to appear with "short" and "long".
Ditto with "unsigned" and "long long".
* gdb.java/jmain.exp: Do not enclose methods names in single
quotes.
* gdb.java/jmisc.exp: Likewise.
* gdb.java/jprint.exp: Likewise.
* gdb.python/py-symbol.exp: Update expected "linkage_name" value.
From Jan Kratochvil <jan.kratochvil@redhat.com>:
* gdb.cp/exception.exp (backtrace after first throw)
(backtrace after second throw): Allow a namespace before __cxa_throw.
(backtrace after first catch, backtrace after second catch): Allow
a namespace before __cxa_begin_catch.
* gdb.cp/cpexprs.exp: New file.
* gdb.cp/cpexprs.cc: New file.
From Daniel Jacobowitz <dan@codesourcery.com>
* gdb.cp/cpexprs.exp (escape): Delete. Change all callers
to use string_to_regexp.
(ctor, dtor): New functions. Use them to match constructor
and destructor function types.
(Top level): Use runto_main.
2010-03-09 18:08:05 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in main(\\((|void)\\))? at.*$srcfile:49\r
1999-04-16 01:35:26 +00:00
\[\t \]+breakpoint already hit 1 time\r
2002-04-18 03:24:20 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(char\\) at.*$srcfile:111\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(signed char\\) at.*$srcfile:112\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(unsigned char\\) at.*$srcfile:113\r
* gdb.cp/cp-relocate.exp: Remove single-quoting of C++ methods.
* gdb.cp/cplusfuncs.cc (dm_type_short): New function.
(dm_type_long): New function.
(dm_type_unsigned_short): New function.
(dm_type_unsigned_long): New function.
(myint): New typedef.
* gdb.cp/cplusfuncs.exp (probe_demangler): Add tests for short,
long, unsigned shor and long, operator char*, and typedef.
(test_lookup_operator_functions): Add operator char* test.
(test_paddr_operator_functions): Likewise.
(test_paddr_overloaded_functions): Use probe values for
short, long, and unsigned short and long.
(test_paddr_hairy_functions): If the demangler probe detected
gdb type printers, "expect" them. Otherwise "expect" the v2 or v3
demangler.
* gdb.cp/expand-sals.exp: Backtrace may contain class names.
* gdb.cp/member-ptr.exp: Refine expected result for "print pmf"
and "print null_pmf".
Add test "ptype a.*pmf".
* gdb.cp/overload.exp: Allow optional "int" to appear with
"short" and "long".
* gdb.cp/ovldbreak.exp: Use append to construct super-duper
long expect value for men_overload1arg.
Allow "int" to appear with "short" and "long".
When testing "info break", add argument for main (void).
Also allow "int" to appear with "short" and "long".
Ditto with "unsigned" and "long long".
* gdb.java/jmain.exp: Do not enclose methods names in single
quotes.
* gdb.java/jmisc.exp: Likewise.
* gdb.java/jprint.exp: Likewise.
* gdb.python/py-symbol.exp: Update expected "linkage_name" value.
From Jan Kratochvil <jan.kratochvil@redhat.com>:
* gdb.cp/exception.exp (backtrace after first throw)
(backtrace after second throw): Allow a namespace before __cxa_throw.
(backtrace after first catch, backtrace after second catch): Allow
a namespace before __cxa_begin_catch.
* gdb.cp/cpexprs.exp: New file.
* gdb.cp/cpexprs.cc: New file.
From Daniel Jacobowitz <dan@codesourcery.com>
* gdb.cp/cpexprs.exp (escape): Delete. Change all callers
to use string_to_regexp.
(ctor, dtor): New functions. Use them to match constructor
and destructor function types.
(Top level): Use runto_main.
2010-03-09 18:08:05 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(short( int)?\\) at.*$srcfile:114\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\((unsigned short|short unsigned)( int)?\\) at.*$srcfile:115\r
2002-04-18 03:24:20 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(int\\) at.*$srcfile:116\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\((unsigned|unsigned int)\\) at.*$srcfile:117\r
* gdb.cp/cp-relocate.exp: Remove single-quoting of C++ methods.
* gdb.cp/cplusfuncs.cc (dm_type_short): New function.
(dm_type_long): New function.
(dm_type_unsigned_short): New function.
(dm_type_unsigned_long): New function.
(myint): New typedef.
* gdb.cp/cplusfuncs.exp (probe_demangler): Add tests for short,
long, unsigned shor and long, operator char*, and typedef.
(test_lookup_operator_functions): Add operator char* test.
(test_paddr_operator_functions): Likewise.
(test_paddr_overloaded_functions): Use probe values for
short, long, and unsigned short and long.
(test_paddr_hairy_functions): If the demangler probe detected
gdb type printers, "expect" them. Otherwise "expect" the v2 or v3
demangler.
* gdb.cp/expand-sals.exp: Backtrace may contain class names.
* gdb.cp/member-ptr.exp: Refine expected result for "print pmf"
and "print null_pmf".
Add test "ptype a.*pmf".
* gdb.cp/overload.exp: Allow optional "int" to appear with
"short" and "long".
* gdb.cp/ovldbreak.exp: Use append to construct super-duper
long expect value for men_overload1arg.
Allow "int" to appear with "short" and "long".
When testing "info break", add argument for main (void).
Also allow "int" to appear with "short" and "long".
Ditto with "unsigned" and "long long".
* gdb.java/jmain.exp: Do not enclose methods names in single
quotes.
* gdb.java/jmisc.exp: Likewise.
* gdb.java/jprint.exp: Likewise.
* gdb.python/py-symbol.exp: Update expected "linkage_name" value.
From Jan Kratochvil <jan.kratochvil@redhat.com>:
* gdb.cp/exception.exp (backtrace after first throw)
(backtrace after second throw): Allow a namespace before __cxa_throw.
(backtrace after first catch, backtrace after second catch): Allow
a namespace before __cxa_begin_catch.
* gdb.cp/cpexprs.exp: New file.
* gdb.cp/cpexprs.cc: New file.
From Daniel Jacobowitz <dan@codesourcery.com>
* gdb.cp/cpexprs.exp (escape): Delete. Change all callers
to use string_to_regexp.
(ctor, dtor): New functions. Use them to match constructor
and destructor function types.
(Top level): Use runto_main.
2010-03-09 18:08:05 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(long( int)?\\) at.*$srcfile:118\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\((unsigned long|long unsigned)( int)?\\) at.*$srcfile:119\r
2002-04-18 03:24:20 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(float\\) at.*$srcfile:120\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(double\\) at.*$srcfile:121\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\((void|)\\) at.*$srcfile:110" \
2001-01-28 23:49:43 +00:00
"breakpoint info (after setting one-by-one)"
1999-04-16 01:35:26 +00:00
2001-01-28 23:49:43 +00:00
# Test choice "cancel".
# This is copy-and-paste from set_bp_overloaded.
1999-04-16 01:35:26 +00:00
send_gdb "break foo::overload1arg\n"
gdb_expect {
2001-01-28 23:49:43 +00:00
-re "$menu_overload1arg" {
pass "bp menu for foo::overload1arg choice cancel"
# Choose cancel.
send_gdb "0\n"
gdb_expect {
-re "canceled\r\n$gdb_prompt $" {
pass "set bp on overload1arg canceled"
}
-re "cancelled\r\n$gdb_prompt $" {
pass "set bp on overload1arg canceled"
}
-re ".*$gdb_prompt $" {
fail "set bp on overload1arg canceled (bad message)"
}
timeout {
fail "set bp on overload1arg canceled (timeout)"
take_gdb_out_of_choice_menu
}
}
}
-re ".*\r\n> " {
fail "bp menu for foo::overload1arg choice cancel (bad menu)"
take_gdb_out_of_choice_menu
}
-re ".*$gdb_prompt $" {
fail "bp menu for foo::overload1arg choice cancel (no menu)"
}
timeout {
fail "bp menu for foo::overload1arg choice cancel (timeout)"
take_gdb_out_of_choice_menu
}
}
1999-04-16 01:35:26 +00:00
gdb_test "info break" \
2008-02-26 08:14:11 +00:00
"Num Type\[\t \]+Disp Enb Address\[\t \]+What.*
* gdb.cp/cp-relocate.exp: Remove single-quoting of C++ methods.
* gdb.cp/cplusfuncs.cc (dm_type_short): New function.
(dm_type_long): New function.
(dm_type_unsigned_short): New function.
(dm_type_unsigned_long): New function.
(myint): New typedef.
* gdb.cp/cplusfuncs.exp (probe_demangler): Add tests for short,
long, unsigned shor and long, operator char*, and typedef.
(test_lookup_operator_functions): Add operator char* test.
(test_paddr_operator_functions): Likewise.
(test_paddr_overloaded_functions): Use probe values for
short, long, and unsigned short and long.
(test_paddr_hairy_functions): If the demangler probe detected
gdb type printers, "expect" them. Otherwise "expect" the v2 or v3
demangler.
* gdb.cp/expand-sals.exp: Backtrace may contain class names.
* gdb.cp/member-ptr.exp: Refine expected result for "print pmf"
and "print null_pmf".
Add test "ptype a.*pmf".
* gdb.cp/overload.exp: Allow optional "int" to appear with
"short" and "long".
* gdb.cp/ovldbreak.exp: Use append to construct super-duper
long expect value for men_overload1arg.
Allow "int" to appear with "short" and "long".
When testing "info break", add argument for main (void).
Also allow "int" to appear with "short" and "long".
Ditto with "unsigned" and "long long".
* gdb.java/jmain.exp: Do not enclose methods names in single
quotes.
* gdb.java/jmisc.exp: Likewise.
* gdb.java/jprint.exp: Likewise.
* gdb.python/py-symbol.exp: Update expected "linkage_name" value.
From Jan Kratochvil <jan.kratochvil@redhat.com>:
* gdb.cp/exception.exp (backtrace after first throw)
(backtrace after second throw): Allow a namespace before __cxa_throw.
(backtrace after first catch, backtrace after second catch): Allow
a namespace before __cxa_begin_catch.
* gdb.cp/cpexprs.exp: New file.
* gdb.cp/cpexprs.cc: New file.
From Daniel Jacobowitz <dan@codesourcery.com>
* gdb.cp/cpexprs.exp (escape): Delete. Change all callers
to use string_to_regexp.
(ctor, dtor): New functions. Use them to match constructor
and destructor function types.
(Top level): Use runto_main.
2010-03-09 18:08:05 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in main(\\((|void)\\))? at.*$srcfile:49\r
1999-04-16 01:35:26 +00:00
\[\t \]+breakpoint already hit 1 time\r
2002-04-18 03:24:20 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(char\\) at.*$srcfile:111\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(signed char\\) at.*$srcfile:112\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(unsigned char\\) at.*$srcfile:113\r
* gdb.cp/cp-relocate.exp: Remove single-quoting of C++ methods.
* gdb.cp/cplusfuncs.cc (dm_type_short): New function.
(dm_type_long): New function.
(dm_type_unsigned_short): New function.
(dm_type_unsigned_long): New function.
(myint): New typedef.
* gdb.cp/cplusfuncs.exp (probe_demangler): Add tests for short,
long, unsigned shor and long, operator char*, and typedef.
(test_lookup_operator_functions): Add operator char* test.
(test_paddr_operator_functions): Likewise.
(test_paddr_overloaded_functions): Use probe values for
short, long, and unsigned short and long.
(test_paddr_hairy_functions): If the demangler probe detected
gdb type printers, "expect" them. Otherwise "expect" the v2 or v3
demangler.
* gdb.cp/expand-sals.exp: Backtrace may contain class names.
* gdb.cp/member-ptr.exp: Refine expected result for "print pmf"
and "print null_pmf".
Add test "ptype a.*pmf".
* gdb.cp/overload.exp: Allow optional "int" to appear with
"short" and "long".
* gdb.cp/ovldbreak.exp: Use append to construct super-duper
long expect value for men_overload1arg.
Allow "int" to appear with "short" and "long".
When testing "info break", add argument for main (void).
Also allow "int" to appear with "short" and "long".
Ditto with "unsigned" and "long long".
* gdb.java/jmain.exp: Do not enclose methods names in single
quotes.
* gdb.java/jmisc.exp: Likewise.
* gdb.java/jprint.exp: Likewise.
* gdb.python/py-symbol.exp: Update expected "linkage_name" value.
From Jan Kratochvil <jan.kratochvil@redhat.com>:
* gdb.cp/exception.exp (backtrace after first throw)
(backtrace after second throw): Allow a namespace before __cxa_throw.
(backtrace after first catch, backtrace after second catch): Allow
a namespace before __cxa_begin_catch.
* gdb.cp/cpexprs.exp: New file.
* gdb.cp/cpexprs.cc: New file.
From Daniel Jacobowitz <dan@codesourcery.com>
* gdb.cp/cpexprs.exp (escape): Delete. Change all callers
to use string_to_regexp.
(ctor, dtor): New functions. Use them to match constructor
and destructor function types.
(Top level): Use runto_main.
2010-03-09 18:08:05 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(short( int)?\\) at.*$srcfile:114\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\((unsigned short|short unsigned)( int)?\\) at.*$srcfile:115\r
2002-04-18 03:24:20 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(int\\) at.*$srcfile:116\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\((unsigned|unsigned int)\\) at.*$srcfile:117\r
* gdb.cp/cp-relocate.exp: Remove single-quoting of C++ methods.
* gdb.cp/cplusfuncs.cc (dm_type_short): New function.
(dm_type_long): New function.
(dm_type_unsigned_short): New function.
(dm_type_unsigned_long): New function.
(myint): New typedef.
* gdb.cp/cplusfuncs.exp (probe_demangler): Add tests for short,
long, unsigned shor and long, operator char*, and typedef.
(test_lookup_operator_functions): Add operator char* test.
(test_paddr_operator_functions): Likewise.
(test_paddr_overloaded_functions): Use probe values for
short, long, and unsigned short and long.
(test_paddr_hairy_functions): If the demangler probe detected
gdb type printers, "expect" them. Otherwise "expect" the v2 or v3
demangler.
* gdb.cp/expand-sals.exp: Backtrace may contain class names.
* gdb.cp/member-ptr.exp: Refine expected result for "print pmf"
and "print null_pmf".
Add test "ptype a.*pmf".
* gdb.cp/overload.exp: Allow optional "int" to appear with
"short" and "long".
* gdb.cp/ovldbreak.exp: Use append to construct super-duper
long expect value for men_overload1arg.
Allow "int" to appear with "short" and "long".
When testing "info break", add argument for main (void).
Also allow "int" to appear with "short" and "long".
Ditto with "unsigned" and "long long".
* gdb.java/jmain.exp: Do not enclose methods names in single
quotes.
* gdb.java/jmisc.exp: Likewise.
* gdb.java/jprint.exp: Likewise.
* gdb.python/py-symbol.exp: Update expected "linkage_name" value.
From Jan Kratochvil <jan.kratochvil@redhat.com>:
* gdb.cp/exception.exp (backtrace after first throw)
(backtrace after second throw): Allow a namespace before __cxa_throw.
(backtrace after first catch, backtrace after second catch): Allow
a namespace before __cxa_begin_catch.
* gdb.cp/cpexprs.exp: New file.
* gdb.cp/cpexprs.cc: New file.
From Daniel Jacobowitz <dan@codesourcery.com>
* gdb.cp/cpexprs.exp (escape): Delete. Change all callers
to use string_to_regexp.
(ctor, dtor): New functions. Use them to match constructor
and destructor function types.
(Top level): Use runto_main.
2010-03-09 18:08:05 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(long( int)?\\) at.*$srcfile:118\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\((unsigned long|long unsigned)( int)?\\) at.*$srcfile:119\r
2002-04-18 03:24:20 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(float\\) at.*$srcfile:120\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(double\\) at.*$srcfile:121\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\((void|)\\) at.*$srcfile:110" \
2001-01-28 23:49:43 +00:00
"breakpoint info (after cancel)"
1999-04-16 01:35:26 +00:00
2001-01-28 23:49:43 +00:00
# Delete these breakpoints.
1999-04-16 01:35:26 +00:00
send_gdb "delete breakpoints\n"
gdb_expect {
2001-01-28 23:49:43 +00:00
-re "Delete all breakpoints.* $" {
1999-04-16 01:35:26 +00:00
send_gdb "y\n"
gdb_expect {
-re ".*$gdb_prompt $" {
2001-01-28 23:49:43 +00:00
pass "delete all breakpoints"
}
timeout {
fail "delete all breakpoints (timeout)"
1999-04-16 01:35:26 +00:00
}
}
}
2001-01-28 23:49:43 +00:00
timeout {
fail "delete all breakpoints (timeout)"
}
1999-04-16 01:35:26 +00:00
}
2001-01-28 23:49:43 +00:00
gdb_test "info breakpoints" "No breakpoints or watchpoints." "breakpoint info (after delete)"
1999-04-16 01:35:26 +00:00
2001-01-28 23:49:43 +00:00
# Test choice "all".
# This is copy-and-paste from set_bp_overloaded.
1999-04-16 01:35:26 +00:00
2001-01-28 23:49:43 +00:00
send_gdb "break foo::overload1arg\n"
gdb_expect {
-re "$menu_overload1arg" {
pass "bp menu for foo::overload1arg choice all"
# Choose all.
send_gdb "1\n"
gdb_expect {
2005-03-05 13:31:26 +00:00
-re "Breakpoint $decimal at $hex: file.*$srcfile, line 121.\r\nBreakpoint $decimal at $hex: file.*$srcfile, line 120.\r\nBreakpoint $decimal at $hex: file.*$srcfile, line 119.\r\nBreakpoint $decimal at $hex: file.*$srcfile, line 118.\r\nBreakpoint $decimal at $hex: file.*$srcfile, line 117.\r\nBreakpoint $decimal at $hex: file.*$srcfile, line 116.\r\nBreakpoint $decimal at $hex: file.*$srcfile, line 115.\r\nBreakpoint $decimal at $hex: file.*$srcfile, line 114.\r\nBreakpoint $decimal at $hex: file.*$srcfile, line 113.\r\nBreakpoint $decimal at $hex: file.*$srcfile, line 112.\r\nBreakpoint $decimal at $hex: file.*$srcfile, line 111.\r\nBreakpoint $decimal at $hex: file.*$srcfile, line 110.\r\nwarning: Multiple breakpoints were set.\r\nUse the .delete. command to delete unwanted breakpoints.\r\n$gdb_prompt $" {
2001-01-28 23:49:43 +00:00
pass "set bp on overload1arg all"
}
-re ".*$gdb_prompt $" {
fail "set bp on overload1arg all (bad message)"
}
timeout {
fail "set bp on overload1arg all (timeout)"
take_gdb_out_of_choice_menu
}
}
}
-re ".*\r\n> " {
fail "bp menu for foo::overload1arg choice all (bad menu)"
take_gdb_out_of_choice_menu
}
-re ".*$gdb_prompt $" {
fail "bp menu for foo::overload1arg choice all (no menu)"
}
timeout {
fail "bp menu for foo::overload1arg choice all (timeout)"
take_gdb_out_of_choice_menu
}
}
1999-04-16 01:35:26 +00:00
gdb_test "info break" \
2008-02-26 08:14:11 +00:00
"Num Type\[\t \]+Disp Enb Address\[\t \]+What.*
2002-04-18 03:24:20 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(double\\) at.*$srcfile:121\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(float\\) at.*$srcfile:120\r
* gdb.cp/cp-relocate.exp: Remove single-quoting of C++ methods.
* gdb.cp/cplusfuncs.cc (dm_type_short): New function.
(dm_type_long): New function.
(dm_type_unsigned_short): New function.
(dm_type_unsigned_long): New function.
(myint): New typedef.
* gdb.cp/cplusfuncs.exp (probe_demangler): Add tests for short,
long, unsigned shor and long, operator char*, and typedef.
(test_lookup_operator_functions): Add operator char* test.
(test_paddr_operator_functions): Likewise.
(test_paddr_overloaded_functions): Use probe values for
short, long, and unsigned short and long.
(test_paddr_hairy_functions): If the demangler probe detected
gdb type printers, "expect" them. Otherwise "expect" the v2 or v3
demangler.
* gdb.cp/expand-sals.exp: Backtrace may contain class names.
* gdb.cp/member-ptr.exp: Refine expected result for "print pmf"
and "print null_pmf".
Add test "ptype a.*pmf".
* gdb.cp/overload.exp: Allow optional "int" to appear with
"short" and "long".
* gdb.cp/ovldbreak.exp: Use append to construct super-duper
long expect value for men_overload1arg.
Allow "int" to appear with "short" and "long".
When testing "info break", add argument for main (void).
Also allow "int" to appear with "short" and "long".
Ditto with "unsigned" and "long long".
* gdb.java/jmain.exp: Do not enclose methods names in single
quotes.
* gdb.java/jmisc.exp: Likewise.
* gdb.java/jprint.exp: Likewise.
* gdb.python/py-symbol.exp: Update expected "linkage_name" value.
From Jan Kratochvil <jan.kratochvil@redhat.com>:
* gdb.cp/exception.exp (backtrace after first throw)
(backtrace after second throw): Allow a namespace before __cxa_throw.
(backtrace after first catch, backtrace after second catch): Allow
a namespace before __cxa_begin_catch.
* gdb.cp/cpexprs.exp: New file.
* gdb.cp/cpexprs.cc: New file.
From Daniel Jacobowitz <dan@codesourcery.com>
* gdb.cp/cpexprs.exp (escape): Delete. Change all callers
to use string_to_regexp.
(ctor, dtor): New functions. Use them to match constructor
and destructor function types.
(Top level): Use runto_main.
2010-03-09 18:08:05 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\((unsigned long|long unsigned)( int)?\\) at.*$srcfile:119\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(long( int)?\\) at.*$srcfile:118\r
2002-04-18 03:24:20 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\((unsigned|unsigned int)\\) at.*$srcfile:117\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(int\\) at.*$srcfile:116\r
* gdb.cp/cp-relocate.exp: Remove single-quoting of C++ methods.
* gdb.cp/cplusfuncs.cc (dm_type_short): New function.
(dm_type_long): New function.
(dm_type_unsigned_short): New function.
(dm_type_unsigned_long): New function.
(myint): New typedef.
* gdb.cp/cplusfuncs.exp (probe_demangler): Add tests for short,
long, unsigned shor and long, operator char*, and typedef.
(test_lookup_operator_functions): Add operator char* test.
(test_paddr_operator_functions): Likewise.
(test_paddr_overloaded_functions): Use probe values for
short, long, and unsigned short and long.
(test_paddr_hairy_functions): If the demangler probe detected
gdb type printers, "expect" them. Otherwise "expect" the v2 or v3
demangler.
* gdb.cp/expand-sals.exp: Backtrace may contain class names.
* gdb.cp/member-ptr.exp: Refine expected result for "print pmf"
and "print null_pmf".
Add test "ptype a.*pmf".
* gdb.cp/overload.exp: Allow optional "int" to appear with
"short" and "long".
* gdb.cp/ovldbreak.exp: Use append to construct super-duper
long expect value for men_overload1arg.
Allow "int" to appear with "short" and "long".
When testing "info break", add argument for main (void).
Also allow "int" to appear with "short" and "long".
Ditto with "unsigned" and "long long".
* gdb.java/jmain.exp: Do not enclose methods names in single
quotes.
* gdb.java/jmisc.exp: Likewise.
* gdb.java/jprint.exp: Likewise.
* gdb.python/py-symbol.exp: Update expected "linkage_name" value.
From Jan Kratochvil <jan.kratochvil@redhat.com>:
* gdb.cp/exception.exp (backtrace after first throw)
(backtrace after second throw): Allow a namespace before __cxa_throw.
(backtrace after first catch, backtrace after second catch): Allow
a namespace before __cxa_begin_catch.
* gdb.cp/cpexprs.exp: New file.
* gdb.cp/cpexprs.cc: New file.
From Daniel Jacobowitz <dan@codesourcery.com>
* gdb.cp/cpexprs.exp (escape): Delete. Change all callers
to use string_to_regexp.
(ctor, dtor): New functions. Use them to match constructor
and destructor function types.
(Top level): Use runto_main.
2010-03-09 18:08:05 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\((unsigned short|short unsigned)( int)?\\) at.*$srcfile:115\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(short( int)?\\) at.*$srcfile:114\r
2002-04-18 03:24:20 +00:00
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(unsigned char\\) at.*$srcfile:113\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(signed char\\) at.*$srcfile:112\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\(char\\) at.*$srcfile:111\r
\[0-9\]+\[\t \]+breakpoint keep y\[\t \]+$hex\[\t \]+in foo::overload1arg\\((void|)\\) at.*$srcfile:110" \
2001-01-28 23:49:43 +00:00
"breakpoint info (after setting on all)"
1999-04-16 01:35:26 +00:00
2001-01-28 23:49:43 +00:00
# Run through each breakpoint.
2003-02-04 01:09:03 +00:00
# NOTE: carlton/2003-02-03: I'm seeing failures on some of the tests,
# with the wrong arg being printed out. Michael Chastain sees
# failures at times, too, albeit fewer than I do.
proc continue_to_bp_overloaded {might_kfail bpnumber argtype actuals} {
2000-02-05 07:30:26 +00:00
global gdb_prompt hex decimal srcfile
2001-01-28 23:49:43 +00:00
send_gdb "continue\n"
1999-04-16 01:35:26 +00:00
gdb_expect {
2001-01-28 23:49:43 +00:00
-re "Continuing.\r\n\r\nBreakpoint ${bpnumber}, (${hex} in )?foo::overload1arg(\\(${argtype}\\))? \\(this=${hex}(, )?${actuals}\\) at.*${srcfile}:${decimal}\r\n${decimal}\[\t \]+int foo::overload1arg \\(${argtype}( arg)?\\).*\r\n.*$gdb_prompt $" {
pass "continue to bp overloaded : ${argtype}"
}
2003-02-04 01:09:03 +00:00
-re "Continuing.\r\n\r\nBreakpoint ${bpnumber}, (${hex} in )?foo::overload1arg(\\(${argtype}\\))? \\(this=${hex}, arg=.*\\) at.*${srcfile}:${decimal}\r\n${decimal}\[\t \]+int foo::overload1arg \\(${argtype}( arg)?\\).*\r\n.*$gdb_prompt $" {
if $might_kfail {
kfail "gdb/1025" "continue to bp overloaded : ${argtype}"
} else {
fail "continue to bp overloaded : ${argtype}"
}
}
2001-01-28 23:49:43 +00:00
-re ".*$gdb_prompt $" {
fail "continue to bp overloaded : ${argtype}"
}
timeout {
fail "continue to bp overloaded : ${argtype} (timeout)"
}
1999-04-16 01:35:26 +00:00
}
2000-02-05 07:30:26 +00:00
}
1999-04-16 01:35:26 +00:00
2003-02-04 01:09:03 +00:00
continue_to_bp_overloaded 0 25 "(void|)" ""
continue_to_bp_overloaded 1 24 "char" "arg=2 \\'\\\\002\\'"
continue_to_bp_overloaded 1 23 "signed char" "arg=3 \\'\\\\003\\'"
continue_to_bp_overloaded 1 22 "unsigned char" "arg=4 \\'\\\\004\\'"
continue_to_bp_overloaded 1 21 "short" "arg=5"
continue_to_bp_overloaded 1 20 "unsigned short" "arg=6"
continue_to_bp_overloaded 0 19 "int" "arg=7"
continue_to_bp_overloaded 0 18 "(unsigned|unsigned int)" "arg=8"
continue_to_bp_overloaded 0 17 "long" "arg=9"
continue_to_bp_overloaded 0 16 "unsigned long" "arg=10"
continue_to_bp_overloaded 0 15 "float" "arg=100"
continue_to_bp_overloaded 1 14 "double" "arg=200"
2001-01-28 23:49:43 +00:00
2008-04-03 21:42:33 +00:00
# Test breaking on an overloaded function when multiple-symbols
# is set to "cancel"
gdb_test "set multiple-symbols cancel" ""
gdb_test "break foo::foofunc" \
"canceled.*"
# Test breaking on an overloaded function when multiple-symbols
# is set to "all"
gdb_test "set multiple-symbols all" ""
gdb_test "break foo::foofunc" \
"Breakpoint \[0-9\]+ at ${hex}: file .*ovldbreak\\.cc, line \[0-9\]+\\.\r\nBreakpoint \[0-9\]+ at ${hex}: file .*ovldbreak\\.cc, line \[0-9\]+\\.\r\nwarning: Multiple breakpoints were set\\.\r\nUse the \"delete\" command to delete unwanted breakpoints\\."
2000-02-05 07:30:26 +00:00
2001-01-28 23:49:43 +00:00
# That's all, folks.
2000-02-05 07:30:26 +00:00
gdb_continue_to_end "finish program"