gdb/testsuite/
* gdb.cp/static-method.exp (have_gcc_45682_fixed, info addr A::func()): New variable, new test. (list static-method.cc:xxx::(anonymous namespace)::A::func) (list 'static-method.cc:xxx::(anonymous namespace)::A::func') (list 'static-method.cc':'xxx::(anonymous namespace)::A::func') (list static-method.cc:'xxx::(anonymous namespace)::A::func'): KFAIL them if HAVE_GCC_45682_FIXED is not set.
This commit is contained in:
parent
4511b1ba87
commit
0a00efc364
@ -1,3 +1,13 @@
|
||||
2011-12-10 Jan Kratochvil <jan.kratochvil@redhat.com>
|
||||
|
||||
* gdb.cp/static-method.exp (have_gcc_45682_fixed, info addr A::func()):
|
||||
New variable, new test.
|
||||
(list static-method.cc:xxx::(anonymous namespace)::A::func)
|
||||
(list 'static-method.cc:xxx::(anonymous namespace)::A::func')
|
||||
(list 'static-method.cc':'xxx::(anonymous namespace)::A::func')
|
||||
(list static-method.cc:'xxx::(anonymous namespace)::A::func'): KFAIL
|
||||
them if HAVE_GCC_45682_FIXED is not set.
|
||||
|
||||
2011-12-10 Yao Qi <yao@codesourcery.com>
|
||||
|
||||
* gdb.trace/status-stop.exp: New.
|
||||
|
@ -48,6 +48,23 @@ if {[prepare_for_testing $testfile $testfile $srcfile {c++ debug}]} {
|
||||
return -1
|
||||
}
|
||||
|
||||
# The GDB workaround for GCC PR debug/45682 does not apply as it requires
|
||||
# DW_AT_linkage_name of methods. The whole class A is in anonymous namespace,
|
||||
# therefore not accessible outside of the CU (compilation unit) and therefore
|
||||
# GCC does not produce DW_AT_linkage_name for such methods.
|
||||
|
||||
set have_gcc_45682_fixed 1
|
||||
set test "info addr A::func()"
|
||||
gdb_test_multiple $test $test {
|
||||
-re "No symbol \"A::func\\(\\)\" in current context\\.\r\n$gdb_prompt $" {
|
||||
pass $test
|
||||
}
|
||||
-re "Symbol \"A::func\\(\\)\" is a function at address .*\r\n$gdb_prompt $" {
|
||||
kfail gcc/45682 $test
|
||||
set have_gcc_45682_fixed 0
|
||||
}
|
||||
}
|
||||
|
||||
if {![runto_main]} {
|
||||
perror "couldn't run to breakpoint"
|
||||
continue
|
||||
@ -68,9 +85,25 @@ foreach test $methods {
|
||||
|
||||
# Test whether the function/method can be "list"ed
|
||||
# with the filename pre-pended.
|
||||
if {[string compare $test "xxx::${ans}::A::func"] == 0
|
||||
&& !$have_gcc_45682_fixed} {
|
||||
setup_kfail gcc/45682 "*-*-*"
|
||||
}
|
||||
gdb_test "list ${srcfile}:$test" $result
|
||||
if {[string compare $test "xxx::${ans}::A::func"] == 0
|
||||
&& !$have_gcc_45682_fixed} {
|
||||
setup_kfail gcc/45682 "*-*-*"
|
||||
}
|
||||
gdb_test "list '${srcfile}:$test'" $result
|
||||
if {[string compare $test "xxx::${ans}::A::func"] == 0
|
||||
&& !$have_gcc_45682_fixed} {
|
||||
setup_kfail gcc/45682 "*-*-*"
|
||||
}
|
||||
gdb_test "list '${srcfile}':'$test'" $result
|
||||
if {[string compare $test "xxx::${ans}::A::func"] == 0
|
||||
&& !$have_gcc_45682_fixed} {
|
||||
setup_kfail gcc/45682 "*-*-*"
|
||||
}
|
||||
gdb_test "list ${srcfile}:'$test'" $result
|
||||
|
||||
# Test setting and hitting a breakoint at the function/method.
|
||||
|
Loading…
x
Reference in New Issue
Block a user