@@ -14,15 +14,15 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
gdb_breakpoint [gdb_get_line_number "break-here"]
gdb_continue_to_breakpoint "break-here"
@@ -137,11 +137,11 @@ close $outfile
standard_testfile $filename
if {[prepare_for_testing "failed to prepare" $testfile $srcfile \
{debug nowarnings c++ additional_flags=-std=c++11}]} {
- return -1
+ return
}
if {![runto_main]} {
perror "test suppressed"
return
@@ -31,11 +31,11 @@ if {[test_compiler_info {gcc-[0-9]-*}]} {
set additional_flags "additional_flags=-Wno-inaccessible-base"
}
if {[prepare_for_testing "failed to prepare" $testfile $srcfile \
[list debug c++ $additional_flags]]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -24,11 +24,11 @@ require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile \
{debug c++ nowarnings}]} {
- return -1
+ return
}
# This testcase cannot use runto_main because of the different prompt
# we get when using annotation level 2.
#
@@ -24,11 +24,11 @@ require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile \
{debug c++ nowarnings}]} {
- return -1
+ return
}
# This testcase cannot use runto_main because of the different prompt
# we get when using annotation level 2.
#
@@ -20,11 +20,11 @@
require allow_cplus_tests
standard_testfile .cc anon-ns2.cc
if {[prepare_for_testing "failed to prepare" $testfile "$srcfile $srcfile2" {c++ debug}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -26,11 +26,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
continue
}
@@ -25,9 +25,9 @@ require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
gdb_test "ptype foo" "type = int \\\(Obj\\\)" "no false reference"
@@ -16,15 +16,15 @@
# Test searching enum constant symbols derived from base classes.
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
gdb_breakpoint [gdb_get_line_number "breakpoint 1" $srcfile]
gdb_continue_to_breakpoint "breakpoint 1"
gdb_test "print X" "= A::X" "print enum constant X of class A"
@@ -24,11 +24,11 @@ require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
runto_main
# Testcases for tdep/2075.
@@ -20,10 +20,10 @@ require allow_cplus_tests
standard_testfile .cc
if { [prepare_for_testing "failed to prepare" $testfile "$srcfile"\
{debug c++}] } {
- return -1
+ return
}
gdb_test "break foo" \
"Breakpoint $decimal at $hex: foo\\. \\(2 locations\\)"
@@ -21,11 +21,11 @@ standard_testfile .cc breakpoint-locs-2.cc
include_file breakpoint-locs.h
if { [prepare_for_testing "failed to prepare" $testfile "$srcfile $srcfile2"\
{debug c++}] } {
- return -1
+ return
}
gdb_test "break N1::C1::baz" "\\(2 locations\\)"
if {[have_index $binfile] == ""} {
@@ -30,16 +30,16 @@ require allow_shlib_tests
standard_testfile .cc -lib.cc
set libobj [standard_output_file libfoo.so]
if {[build_executable "build shared library" $libobj $srcfile2 \
{debug c++ shlib}] != 0} {
- return -1
+ return
}
if {[prepare_for_testing "failed to prepare" $testfile $srcfile \
[list debug c++ shlib=$libobj]]} {
- return -1
+ return
}
gdb_load_shlib $libobj
# Place the breakpoint before the shared library has been loaded, the
@@ -47,11 +47,11 @@ gdb_load_shlib $libobj
gdb_test "break foo" "Breakpoint $decimal at $hex"
gdb_test "info breakpoints" "<foo\\(\\)@plt>"
# Runto main, but don't delete all the breakpoints.
if {![runto_main no-delete-breakpoints]} {
- return -1
+ return
}
# The breakpoint should now be showing in `foo` for real.
gdb_test "info breakpoints" \
"\r\n$decimal\\s+\[^\r\n\]+ in foo\\(\\) at \[^\r\n\]+\r\n.*" \
@@ -24,11 +24,11 @@ require allow_cplus_tests
#
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
proc test_breakpoint {name} {
# Restart the program every time, so that a single failure doesn't
# lead to a cascade.
@@ -20,11 +20,11 @@
require allow_stl_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -22,11 +22,11 @@ set objfilecpp [standard_output_file ${testfile}.o]
if {[gdb_compile "$srcdir/$subdir/${srcfile2}" "${objfilec}" object {debug}] != ""
|| [gdb_compile "$srcdir/$subdir/${srcfile}" "${objfilecpp}" object {c++ debug}] != ""
|| [gdb_compile "${objfilecpp} ${objfilec}" "${binfile}" executable {c++ debug}] != ""} {
untested "failed to compile"
- return -1
+ return
}
clean_restart ${::testfile}
runto_main
@@ -30,11 +30,11 @@ lappend flags_debug c++
set flags_nodebug {}
lappend flags_nodebug nodebug
lappend flags_nodebug c++
if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags_debug]} {
- return -1
+ return
}
set asm_file [standard_output_file $srcfile2]
Dwarf::assemble $asm_file {
@@ -103,15 +103,15 @@ Dwarf::assemble $asm_file {
}
}
if { [prepare_for_testing "failed to prepare" ${testfile} \
[list $srcfile $asm_file] $::flags_nodebug] } {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
gdb_test "print global_var.yyy ()" \
"Address requested for identifier \"global_var\" which is in register .*" \
"call method on register local"
@@ -33,11 +33,11 @@ set opts {}
lappend opts debug
lappend opts c++
lappend opts additional_flags=-std=c++11
if {[prepare_for_testing "failed to prepare" $testfile $srcfile $opts]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -213,11 +213,11 @@ gdb_test "print &dynamic_cast<VirtualRight &> (*vlr) == vr" " = true"
gdb_test "print &dynamic_cast<VirtualRight &> (*vl) == vr" " = true"
gdb_test "print &dynamic_cast<VirtualRight &> (*vr) == vr" " = true"
if {[prepare_for_testing "failed to prepare" ${testfile}03 $srcfile2 \
{debug c++ additional_flags=-std=c++03}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -18,15 +18,15 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
gdb_breakpoint [gdb_get_line_number "Break here"]
gdb_continue_to_breakpoint "Break here"
@@ -24,11 +24,11 @@ set flags [list debug c++]
if { [gcc_major_version "clang-*" "c++"] > 10 } {
lappend flags additional_flags=-Wno-non-c-typedef-for-linkage
}
if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} {
- return -1
+ return
}
# Start with "set print object off" and "set print symbol off".
gdb_test_no_output "set print object off"
@@ -32,11 +32,11 @@ if { [test_compiler_info "clang-*" "c++"] } {
lappend flags additional_flags=-Wno-non-c-typedef-for-linkage
}
}
if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} {
- return -1
+ return
}
# Test ptype of class objects.
proc test_ptype_class_objects {} {
@@ -22,11 +22,11 @@ require allow_cplus_tests
# Tests for c++/12273, breakpoint/12803
standard_testfile .cc
# Do NOT compile with debug flag.
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {c++}]} {
- return -1
+ return
}
# Before setting the language, try to set a few simple breakpoints
set min_syms [list \
"GDB<int>::a() const" \
@@ -20,11 +20,11 @@ lappend flags debug
lappend flags c++
lappend flags optimize=-O2
lappend_include_file flags $srcdir/lib/attributes.h
if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} {
- return -1
+ return
}
gdb_test_multiple "break foo" "" {
-re -wrap "\\($decimal locations\\)" {
fail $gdb_test_name
@@ -20,11 +20,11 @@ require {have_compile_flag -std=c++17}
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile \
{c++ debug additional_flags=-std=c++17}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -110,11 +110,11 @@ gdb_test_multiple "info file" "info file" {
}
}
if { $func1_sec == $func2_sec } {
untested "cp-relocate.exp - template functions in same sections"
- return -1
+ return
}
# Now start a clean GDB, for add-symbol-file tests.
clean_restart
@@ -54,19 +54,19 @@ proc test_class_complete {class expr name matches} {
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
# Tests below are about tab-completion, which doesn't work if readline
# library isn't used. Check it first.
if { ![readline_is_used] } {
untested "no tab completion support without readline"
- return -1
+ return
}
# Test that completion is restricted by class name (all methods)
test_class_complete Foo "" "complete class methods" \
[list Foo Foofoo get_foo set_foo ~Foo]
@@ -704,11 +704,11 @@ standard_testfile cpexprs.cc
# Include required flags.
set flags "$flags debug c++"
if {[prepare_for_testing "failed to prepare" $testfile $srcfile "$flags"]} {
- return -1
+ return
}
if {![runto_main]} {
perror "couldn't run to breakpoint"
continue
@@ -18,15 +18,15 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {c++ debug}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
set methods {"bar" "baz"}
set labels {"to_the_top" "get_out_of_here"}
@@ -19,11 +19,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
#
# g++ changed its ABI between 2.95 and 3.0. gdb has two demanglers
# for the two different styles. The two demanglers have some subtle
@@ -25,11 +25,11 @@ require allow_cplus_tests
standard_testfile cttiadd.cc cttiadd1.cc cttiadd2.cc cttiadd3.cc
if {[prepare_for_testing "failed to prepare" $testfile \
[list $srcfile $srcfile2 $srcfile3 $srcfile4] {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -34,11 +34,11 @@ load_lib "cp-support.exp"
standard_testfile derivation.cc derivation2.cc
if {[prepare_for_testing "failed to prepare" $testfile \
[list $srcfile $srcfile2] {debug c++}]} {
- return -1
+ return
}
# Check inheritance of typedefs.
with_test_prefix "before run" {
foreach klass {"A" "D" "E" "F" "A2" "D2"} {
@@ -14,15 +14,15 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
gdb_breakpoint [gdb_get_line_number "Break here"]
gdb_continue_to_breakpoint "Break here"
@@ -22,11 +22,11 @@ require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile \
$srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -16,11 +16,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -33,15 +33,15 @@ set opts {}
lappend opts debug
lappend opts c++
lappend opts additional_flags=-std=c++11
if {[prepare_for_testing "failed to prepare" $testfile $srcfile $opts]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
gdb_breakpoint "breakpt"
gdb_continue_to_breakpoint "stop in breakpt"
@@ -24,15 +24,15 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto 'marker']} {
- return -1
+ return
}
# Returns a buffer corresponding to what GDB replies when asking for
# 'info breakpoint'. The parameters are all the existing breakpoints
# enabled/disable value: 'n' or 'y'.
@@ -19,15 +19,15 @@ require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile \
{debug c++ additional_flags=-std=c++11}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
gdb_test "ptype E1" \
[multi_line \
"type = enum class E1 (: int )?{" \
@@ -33,11 +33,11 @@ set nl "\[\r\n\]+"
require allow_stl_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
# Set a catch catchpoint
gdb_test "catch catch" "Catchpoint ${::decimal} \\(catch\\)" \
@@ -16,20 +16,20 @@
standard_testfile .cc
require allow_cplus_tests
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
if {[skip_libstdcxx_probe_tests]} {
untested "could not find libstdc++ stap probe"
- return -1
+ return
}
proc do_continue_to_catchpoint {name} {
global gdb_prompt
@@ -69,11 +69,11 @@ do_exceptprint_tests "reference to struct" "{mv = 77}"
delete_breakpoints
if {![runto_main]} {
- return -1
+ return
}
with_test_prefix "2nd run" {
gdb_test "catch catch int if \$_exception == 23" \
"Catchpoint ${::decimal} \\(catch\\)" \
@@ -15,14 +15,14 @@
require allow_cplus_tests
set srcfile expand-sals.cc
if { [prepare_for_testing "failed to prepare" expand-sals $srcfile {debug c++}] } {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
gdb_breakpoint [gdb_get_line_number "func-line"]
gdb_continue_to_breakpoint "func" ".*func-line.*"
@@ -18,11 +18,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
runto_main
if { [gdb_breakpoint "c_func"] == 1 } {
@@ -18,11 +18,11 @@ require allow_cplus_tests
standard_testfile .cc
include_file includefile
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -31,11 +31,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
proc get_address { var } {
global expect_out
global gdb_prompt
@@ -28,11 +28,11 @@ require allow_cplus_tests
#
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -30,19 +30,19 @@ include_file gdb2384-base.h
set sofile [standard_output_file gdb2384-base.so]
if { [gdb_compile_shlib $srcdir/$subdir/$srcfile2 $sofile {debug c++}] != ""
|| [gdb_compile $srcdir/$subdir/$srcfile $binfile executable [list debug "c++" shlib=${sofile}]] != ""} {
untested "failed to compile"
- return -1
+ return
}
clean_restart ${::testfile}
gdb_load_shlib ${sofile}
if {![runto_main]} {
- return -1
+ return
}
gdb_breakpoint [gdb_get_line_number "First breakpoint"]
gdb_continue_to_breakpoint "run to 'First breakpoint', first time"
@@ -40,11 +40,11 @@ standard_testfile .cc
# Some targets can't do function calls, so don't even bother with this
# test.
require {!target_info exists gdb,cannot_call_functions}
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -20,11 +20,11 @@ standard_testfile hang1.cc hang2.cc hang3.cc
include_file hang.H
if {[prepare_for_testing "failed to prepare" $testfile \
[list $srcfile $srcfile2 $srcfile3] {debug c++}]} {
- return -1
+ return
}
# As of May 1, 2002, GDB hangs trying to read the debug info for the
# `hang2.o' compilation unit from the executable `hang', when compiled
# by g++ 2.96 with STABS debugging info. Here's what's going on, as
@@ -21,11 +21,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
set gcc_used [test_compiler_info gcc-*-*]
# First test expressions when there is no context.
@@ -20,17 +20,17 @@ set libfile [standard_output_file ${testfile}.so]
set lib_dlopen [shlib_target_file ${testfile}.so]
# Use completely arbitrary file for $libfile source.
if { [gdb_compile_shlib ${srcdir}/${subdir}/${srcfile2} ${libfile} {debug c++}] != ""
|| [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug c++ shlib_load}] } {
- return -1
+ return
}
gdb_load_shlib $libfile
if { ![runto_main] } {
- return -1
+ return
}
for {set i 0} {$i < 10} {incr i} {
gdb_test "p openlib (\"${lib_dlopen}\")" " = 1" "test $i"
# Try to exploit the GDB trashed memory.
@@ -25,11 +25,11 @@ require allow_cplus_tests
load_lib "cp-support.exp"
standard_testfile misc.cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
# Single inheritance, print type definitions.
proc test_ptype_si { } {
@@ -19,11 +19,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -30,11 +30,11 @@ set nl "\[\r\n\]+"
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
#
# set it up at a breakpoint so we can play with the variable values
#
@@ -25,11 +25,11 @@ require allow_cplus_tests
#
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -35,11 +35,11 @@ if { [test_compiler_info gcc-*] && [gcc_major_version] >= 10 } {
lappend flags additional_flags=-fno-eliminate-unused-debug-types
}
if {[prepare_for_testing "failed to prepare" $testfile \
[list $srcfile $srcfile2] $flags]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -23,11 +23,11 @@ require !readnow
set opts {}
lappend opts debug
lappend opts c++
if { [prepare_for_testing "failed to prepare" $testfile $srcfile $opts] } {
- return -1
+ return
}
require {string eq [have_index $binfile] ""}
gdb_test_no_output "maint info symtabs"
@@ -22,11 +22,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -20,11 +20,11 @@ require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {[test_compiler_info {clang-*-*} c++]} {
set using_clang true
} else {
@@ -24,11 +24,11 @@ standard_testfile mb-inline1.cc mb-inline2.cc
set hdrfile "${testfile}.h"
include_file $hdrfile
if {[prepare_for_testing "failed to prepare" $testfile \
[list $srcfile $srcfile2] {debug c++}]} {
- return -1
+ return
}
set bp_location [gdb_get_line_number "set breakpoint here" $hdrfile]
# Set a breakpoint with multiple locations.
@@ -78,11 +78,11 @@ gdb_test_multiple "info break" "disabled breakpoint 1.2" {
delete_breakpoints
set bp_location [gdb_get_line_number "set multi-line breakpoint here" $hdrfile]
if { ![runto_main] } {
- return 0
+ return
}
gdb_test "break $hdrfile:$bp_location" \
"Breakpoint.*at.*: $hdrfile:$bp_location. \\(2 locations\\).*" \
"set multi_line_foo breakpoint"
@@ -20,11 +20,11 @@ require allow_stl_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
set bp_location [gdb_get_line_number "set breakpoint here"]
# Set a breakpoint with multiple locations
@@ -106,11 +106,11 @@ gdb_test "continue" \
delete_breakpoints
set bp_location [gdb_get_line_number "set multi-line breakpoint here"]
if { ![runto_main] } {
- return 0
+ return
}
gdb_test "break $srcfile:$bp_location" \
"Breakpoint.*at.*: $srcfile:$bp_location. \\(2 locations\\).*" \
"set multi_line_foo breakpoint"
@@ -16,11 +16,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -25,11 +25,11 @@ require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -35,11 +35,11 @@ require allow_cplus_tests
# Tests for c++/12266 et al
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile \
{c++ debug additional_flags=-std=c++11}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -24,15 +24,15 @@ set opts {}
lappend opts debug
lappend opts c++
lappend opts additional_flags=-std=c++11
if { [prepare_for_testing "failed to prepare" $testfile $srcfile $opts] } {
- return -1
+ return
}
if {![runto_main]} {
- return 0
+ return
}
gdb_breakpoint [gdb_get_line_number "Break here"]
gdb_continue_to_breakpoint "Break here"
@@ -18,15 +18,15 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
# Set a breakpoint after the bar object is created and the reference is obtained.
gdb_breakpoint [gdb_get_line_number "breakpoint here"]
gdb_continue_to_breakpoint "after reference assignment"
@@ -35,11 +35,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
#
# set it up at a breakpoint so we can play with the variable values
#
@@ -35,11 +35,11 @@ set objmainfile [standard_output_file ${testfile}-main.o]
if {[gdb_compile $srcdir/$subdir/$srcfile $objfile object $nodebug_flags] != ""
|| [gdb_compile $srcdir/$subdir/$srcfile2 $objmainfile object $debug_flags] != ""
|| [gdb_compile "$objfile $objmainfile" $binfile executable $debug_flags] != ""} {
untested "failed to compile"
- return -1
+ return
}
clean_restart ${executable}
gdb_test_no_output "set breakpoint pending off"
@@ -18,11 +18,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
#
# Deduce language of main()
#
@@ -26,15 +26,15 @@ require is_x86_64_m64_target
standard_testfile .S
set csrcfile "${testfile}.cc"
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {nodebug}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
# Set a breakpoint in the lambda in A::doit (). */
set line [gdb_get_line_number "set breakpoint here" $csrcfile]
gdb_breakpoint $line
@@ -15,11 +15,11 @@
standard_testfile .cc namespace-enum-main.cc
if {[prepare_for_testing "failed to prepare" $testfile \
[list $srcfile $srcfile2] {debug c++}]} {
- return -1
+ return
}
gdb_test "print foo::B::B_B" "`foo::B' is not defined as an aggregate type."
gdb_test "print foo::B_B" "foo::B_B"
gdb_test "print A_A" "A_A"
@@ -15,11 +15,11 @@
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
############################################
# Test printing of a variable from a nested
# in a namespace inner to the one which has
@@ -36,11 +36,11 @@ if {[test_compiler_info {gcc-[0-3]-*}]
set xfail_class_types 1
}
if {[prepare_for_testing "failed to prepare" $testfile \
[list $srcfile $srcfile2] {debug c++}]} {
- return -1
+ return
}
gdb_test "show lang" "auto; currently c\\+\\+.*"
#
@@ -20,15 +20,15 @@ require allow_cplus_tests
load_lib "cp-support.exp"
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
gdb_breakpoint [gdb_get_line_number "BP 1"]
gdb_breakpoint [gdb_get_line_number "BP 2"]
gdb_continue_to_breakpoint "BP 1"
@@ -25,11 +25,11 @@ load_lib "cp-support.exp"
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile \
{debug c++}]} {
- return -1
+ return
}
# Build the node given by ID (a number representing the struct S[ID] in
# the source file).
#
@@ -17,20 +17,20 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
if {![skip_unwinder_tests]} {
unsupported "nextoverthrow.exp could not find _Unwind_DebugHook"
- return -1
+ return
}
# Set a temporary breakpoint and then continue to it.
# The breakpoint is set according to a marker in the file.
proc tbreak_and_cont {text} {
@@ -16,19 +16,19 @@
standard_testfile exceptprint.cc
require allow_cplus_tests
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
# This tests that $_exception gives an error when the systemtap probes
# are not available, so simulate this by disabling them.
gdb_test "maint ignore-probes libstdcxx .*" ".*OBJNAME: ''"
if {![runto_main]} {
- return -1
+ return
}
gdb_test "catch throw" "Catchpoint $decimal \\(throw\\)" \
"catch throw"
@@ -35,15 +35,15 @@ if {[have_fvar_tracking]} {
}
}
if {[prepare_for_testing "failed to prepare" $testfile $srcfile [list debug c++ $additional_flags]]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
gdb_breakpoint [gdb_get_line_number "Break here"]
gdb_continue_to_breakpoint "Break here"
@@ -12,10 +12,10 @@
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
if { [prepare_for_testing "failed to prepare" "noparam" "noparam.cc" {debug c++}] } {
- return -1
+ return
}
# Check if GDB does not crash.
gdb_test "p C::m (int)" "no member function matches that type instantiation"
@@ -168,20 +168,20 @@ Dwarf::assemble $asm_file {
}
}
if {[gdb_compile $srcdir/$subdir/$srcfile ${binfile}1.o \
object {c++ debug}] != ""} {
- return -1
+ return
}
if {[gdb_compile $asm_file ${binfile}2.o object {nodebug}] != ""} {
- return -1
+ return
}
if {[gdb_compile [list ${binfile}1.o ${binfile}2.o] \
$binfile executable {c++}] != ""} {
- return -1
+ return
}
clean_restart $testfile
# A procedure to run various tests on aliased namespaces.
@@ -302,16 +302,16 @@ set the_dwarf [format {
} $imports]
Dwarf::assemble $asm_file $the_dwarf
if {[gdb_compile $asm_file ${binfile}3.o object {nodebug}] != ""} {
- return -1
+ return
}
if {[gdb_compile [list ${binfile}1.o ${binfile}3.o] \
${binfile}-r executable {c++}] != ""} {
- return -1
+ return
}
clean_restart
# Set complaints before loading the file. Otherwise the complaint won't
@@ -17,11 +17,11 @@
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -18,11 +18,11 @@
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
############################################
# test printing of namespace imported within
# the function.
@@ -15,11 +15,11 @@
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -17,11 +17,11 @@
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
continue
}
@@ -14,11 +14,11 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
############################################
# Test printing of namespace imported within the function.
@@ -15,11 +15,11 @@
standard_testfile .cc
if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} \
{debug c++ additional_flags=-Wno-unused-comparison}] } {
- return -1
+ return
}
############################################
if {![runto_main]} {
@@ -18,11 +18,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $testfile.cc {c++ debug}]} {
- return -1
+ return
}
gdb_test_no_output "set language c++"
if {[gdb_breakpoint "myclass::func"]} {
@@ -27,11 +27,11 @@ set nl "\[\r\n\]+"
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
# Set it up at a breakpoint so we can play with the variable values.
if {![runto 'marker1']} {
@@ -31,11 +31,11 @@ set timeout 15
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
# set it up at a breakpoint so we can play with the variable values
#
if {![runto_main]} {
@@ -59,11 +59,11 @@ standard_testfile ovsrch1.cc ovsrch2.cc ovsrch3.cc ovsrch4.cc
include_file ovsrch.h
if {[prepare_for_testing "failed to prepare" $testfile \
[list $srcfile $srcfile2 $srcfile3 $srcfile4] {c++ debug}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -25,11 +25,11 @@ set opts {}
lappend opts debug
lappend opts c++
lappend opts additional_flags=-std=c++11
if {[prepare_for_testing "failed to prepare" $testfile $srcfile $opts]} {
- return -1
+ return
}
foreach ordinary {"outer<int>::fn" "outer<char>::fn<short>" "toplev<char>"} {
gdb_breakpoint $ordinary message
clean_restart $testfile
@@ -14,11 +14,11 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
standard_testfile .cc
if { [prepare_for_testing "failed to prepare" ${testfile} ${testfile}.cc {c++ debug}] } {
- return -1
+ return
}
gdb_test_no_output "set breakpoint pending off"
gdb_test "break C::f(long)" {Function "C::f\(long\)" not defined\.}
@@ -14,11 +14,11 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
# Place the breakpoint before inferior gets started. Then the breakpoint
# condition will be re-evaluated in non-C++ startup code.
gdb_breakpoint "C::m if v == 42"
@@ -29,15 +29,15 @@ require allow_cplus_tests
standard_testfile .cc
set options {debug c++ additional_flags=-std=c++11}
if {[prepare_for_testing "failed to prepare" $testfile $srcfile $options]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
# GCC version <= 6 and Clang do not emit DW_AT_defaulted and DW_AT_deleted.
set is_gcc_6_or_older [test_compiler_info {gcc-[0-6]-*}]
set is_clang [test_compiler_info {clang-*}]
@@ -334,15 +334,15 @@ set program [generate_program $classes $stmts]
set srcfile [standard_output_file ${srcfile}]
gdb_produce_source $srcfile $program
set options {debug c++ additional_flags=-std=c++11}
if {[prepare_for_testing "failed to prepare" $testfile $srcfile $options]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
set bp_location [gdb_get_line_number "stop here"]
gdb_breakpoint $bp_location
gdb_continue_to_breakpoint "end of main" ".*return .*;"
@@ -20,9 +20,9 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
gdb_test "print ptm" " = &A::i"
@@ -25,11 +25,11 @@ require allow_cplus_tests
#
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -24,11 +24,11 @@ require allow_cplus_tests
#
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -33,11 +33,11 @@ if { [test_compiler_info gcc-*] && [gcc_major_version] >= 10 } {
# Work around PR gcc/101452.
lappend flags additional_flags=-fno-eliminate-unused-debug-types
}
if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -14,11 +14,11 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -14,11 +14,11 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
standard_testfile .cc
if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug c++}] } {
- return -1
+ return
}
############################################
if {![runto_main]} {
@@ -18,15 +18,15 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
gdb_breakpoint [gdb_get_line_number "Break here"]
gdb_continue_to_breakpoint "Break here"
@@ -18,15 +18,15 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
gdb_breakpoint [gdb_get_line_number "Break here"]
gdb_continue_to_breakpoint "Break here"
@@ -20,11 +20,11 @@ require allow_cplus_tests
load_lib "cp-support.exp"
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -20,11 +20,11 @@ if { [test_compiler_info gcc-*] && [gcc_major_version] >= 10 } {
# Work around PR gcc/101452.
lappend flags additional_flags=-fno-eliminate-unused-debug-types
}
if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -18,11 +18,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -16,11 +16,11 @@
require allow_cplus_tests
standard_testfile bool.cc
if {[prepare_for_testing $testfile.exp $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
runto_main
gdb_breakpoint "return_true"
@@ -23,11 +23,11 @@ set testfile $testfile.o
set binfile [standard_output_file $testfile]
if { [gdb_compile $srcdir/$subdir/$srcfile $binfile object \
{c++ debug}] != "" } {
untested "failed to compile"
- return -1
+ return
}
clean_restart $testfile
gdb_test "print s" " = <incomplete type>"
@@ -20,11 +20,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
set re \
[multi_line \
"type = class A {" \
@@ -26,11 +26,11 @@ require allow_cplus_tests
#
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -180,11 +180,11 @@ require allow_cplus_tests
standard_testfile psmang1.cc psmang2.cc
if {[prepare_for_testing "failed to prepare" $testfile \
[list $srcfile $srcfile2] {debug c++}]} {
- return -1
+ return
}
gdb_test "break s::method1" "Breakpoint .* at .*: file .*psmang1.cc.*"
# We have to exit and restart GDB here, to make sure that all the
@@ -17,11 +17,11 @@ require allow_cplus_tests
standard_testfile .cc
if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}.x" object {debug c++}] != "" } {
untested "failed to compile"
- return -1
+ return
}
clean_restart $testfile.x
# As `main' is not present GDB fails to find the proper inferior language.
@@ -18,11 +18,11 @@
require allow_cplus_tests
standard_testfile .cc
if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} {debug c++}] } {
- return -1
+ return
}
gdb_test "whatis v_my_int" "type = my_int"
gdb_test "ptype v_my_int" "type = int"
@@ -20,11 +20,11 @@ require allow_cplus_tests
load_lib "cp-support.exp"
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -20,11 +20,11 @@ standard_testfile bool.cc .cc
set sofile [standard_output_file ${testfile}.so]
if { [gdb_compile_shlib $srcdir/$subdir/$srcfile2 $sofile {debug c++}] != ""
|| [gdb_compile $srcdir/$subdir/$srcfile $binfile executable [list debug "c++" shlib=${sofile}]] != ""} {
untested "failed to compile"
- return -1
+ return
}
clean_restart $testfile
gdb_load_shlib ${sofile}
@@ -14,11 +14,11 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
standard_testfile .cc
if {[build_executable ${testfile}.exp $testfile ${testfile}.cc {c++ debug}] == -1} {
- return -1
+ return
}
save_vars { GDBFLAGS } {
set GDBFLAGS "$GDBFLAGS -readnow"
clean_restart $testfile
@@ -23,11 +23,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[build_executable $testfile.exp $testfile $srcfile {debug c++}] == -1} {
- return -1
+ return
}
proc gdb_start_again { text } {
global binfile
global srcfile
@@ -23,11 +23,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
#
# set it up at a breakpoint so we can play with the variable values
#
@@ -36,11 +36,11 @@ standard_testfile rtti1.cc rtti2.cc
include_file rtti.h
if {[prepare_for_testing "failed to prepare" $testfile \
[list $srcfile $srcfile2] {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -21,15 +21,15 @@ require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing $testfile.exp $testfile $srcfile \
{debug c++ additional_flags="-std=gnu++11"}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
# Prevent symbol on address 0x0 being printed.
gdb_test_no_output "set print symbol off"
@@ -24,18 +24,18 @@ load_lib "cp-support.exp"
standard_testfile .cc
if {[prepare_for_testing $testfile.exp $testfile $srcfile \
{debug c++ additional_flags="-std=gnu++11"}]} {
- return -1
+ return
}
# Set it up at a breakpoint so we can play with the variable values.
if {![runto 'marker1']} {
untested "couldn't run to marker1"
- return -1
+ return
}
# Prevent symbol on address 0x0 being printed.
gdb_test_no_output "set print symbol off"
gdb_test "up" ".*main.*" "up from marker1"
@@ -20,11 +20,11 @@ require allow_cplus_tests
standard_testfile .cc
if {[build_executable $testfile.exp $testfile $srcfile \
{debug c++ additional_flags="-std=gnu++11"}] == -1} {
- return -1
+ return
}
proc gdb_start_again {text prefix} {
global binfile
global srcfile
@@ -20,22 +20,22 @@ require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing $testfile.exp $testfile $srcfile \
{debug c++ additional_flags="-std=gnu++11"}]} {
- return -1
+ return
}
#
# Set it up at a breakpoint so we can play with the variable values.
#
if {![runto_main]} {
- return -1
+ return
}
if {![runto 'marker1']} {
- return -1
+ return
}
gdb_test "up" ".*main.*" "up from marker1 1"
gdb_test "print rrt" " = \\(short( int)? &&\\) @$hex: -1" "print value of rrt"
@@ -16,11 +16,11 @@
# Test "save breakpoints" + "break -qualified".
standard_testfile .cc
if { [build_executable "failed to prepare" ${testfile} $srcfile {debug c++}] } {
- return -1
+ return
}
proc restart {} {
global testfile
@@ -20,15 +20,15 @@ require allow_cplus_tests
standard_testfile .cc
set exefile $testfile
if {[prepare_for_testing "failed to prepare" $exefile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
- return 0
+ return
}
# Run to a location in the file.
set bp_location [gdb_get_line_number "set breakpoint here"]
@@ -18,11 +18,11 @@
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -41,11 +41,11 @@ require allow_cplus_tests
# Tests for c++/12750
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {c++ debug}]} {
- return -1
+ return
}
# 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
@@ -17,11 +17,11 @@ require allow_cplus_tests
standard_testfile .cc
if { [gdb_compile $srcdir/$subdir/$srcfile $binfile.o object {debug c++}] != ""} {
untested "failed to compile"
- return -1
+ return
}
clean_restart $testfile.o
gdb_test_no_output "set width 80"
@@ -16,15 +16,15 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
gdb_test "print a" \
"static INSTANCE = <same as static member of an already seen type>}}.*" \
"print static member"
@@ -14,11 +14,11 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
standard_testfile .cc
if {[test_compiler_info gcc*] && ![supports_statement_frontiers] } {
- return -1
+ return
}
# Compile the test source with USE_NEXT_INLINE_H defined (when
# use_header is true), or not defined.
proc do_test { use_header } {
@@ -24,9 +24,9 @@ standard_testfile .cc stub-array-size2.cc
include_file stub-array-size.h
if {[prepare_for_testing "failed to prepare" $testfile "$srcfile $srcfile2" \
{c++ debug}]} {
- return -1
+ return
}
gdb_test "print sizeof(a)/sizeof(a\[0\])" "10"
@@ -25,11 +25,11 @@ standard_testfile .cc subtypes-2.cc
include_file subtypes.h
if {[prepare_for_testing "failed to prepare" $testfile \
[list $srcfile $srcfile2] \
{debug c++ additional_flags=-std=c++11}]} {
- return -1
+ return
}
# Xfail for superfluous DW_TAG_lexical_block, gcc PR debug/55541.
set have_xfail [expr {[test_compiler_info gcc-*] && [gcc_major_version] < 5}]
@@ -21,15 +21,15 @@ require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile \
{debug c++ additional_flags=-std=c++11}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
# gcc 4.4 and earlier don't emit enough info for some of our template tests.
set have_older_template_gcc 0
set have_pr_41736_fixed 1
@@ -28,11 +28,11 @@ if { [test_compiler_info gcc-*] && [gcc_major_version] >= 10 } {
# Work around PR gcc/101452.
lappend flags additional_flags=-DGCC_BUG
}
if {[prepare_for_testing "failed to prepare" $testfile $srcfile $flags]} {
- return -1
+ return
}
#
# Test printing of the types of templates.
#
@@ -25,11 +25,11 @@ require allow_stl_tests
#
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -23,10 +23,10 @@ set opts {}
lappend opts debug
lappend opts c++
lappend opts additional_flags=-std=c++11
if {[prepare_for_testing "failed to prepare" $testfile $srcfile $opts]} {
- return -1
+ return
}
gdb_test "print (int)byte_val" "= 128"
gdb_test "print (int)uchar_val" "= 128"
@@ -18,15 +18,15 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
gdb_test "ptype C::x" \
"type = int" \
"ptype typedef base struct member"
@@ -18,17 +18,17 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {c++ debug}]} {
- return -1
+ return
}
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]} {
- return -1
+ return
}
gdb_test "p *v" " = 42" "test typedef"
@@ -16,11 +16,11 @@
standard_testfile .cc
require allow_cplus_tests
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
proc do_typeid_tests {started} {
global hex
@@ -81,11 +81,11 @@ proc do_typeid_tests {started} {
with_test_prefix "before starting" {
do_typeid_tests 0
}
if {![runto_main]} {
- return -1
+ return
}
with_test_prefix "after starting" {
do_typeid_tests 1
}
@@ -22,11 +22,11 @@
require allow_stl_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -13,11 +13,11 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
runto "foo"
# This would cause reading debug info with using_directives pointing to
@@ -21,11 +21,11 @@ require allow_cplus_tests
standard_testfile var-tag.cc var-tag-2.cc var-tag-3.cc var-tag-4.cc
if {[prepare_for_testing "failed to prepare" $testfile \
[list $srcfile $srcfile2 $srcfile3 $srcfile4] {debug c++}]} {
- return -1
+ return
}
proc do_global_tests {lang} {
set invalid_print "Attempt to use a type name as an expression"
@@ -18,11 +18,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -18,11 +18,11 @@
require allow_cplus_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -23,11 +23,11 @@ require allow_cplus_tests
load_lib "cp-support.exp"
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
proc test_ptype_of_classes {} {
# class VA
@@ -23,11 +23,11 @@ require allow_cplus_tests
load_lib "cp-support.exp"
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}
@@ -18,15 +18,15 @@ standard_testfile .cc
set flags {}
lappend flags debug
lappend flags c++
if { [prepare_for_testing "failed to prepare" ${testfile} ${srcfile} $flags] } {
- return -1
+ return
}
if {![runto_main]} {
- return -1
+ return
}
gdb_breakpoint [gdb_get_line_number "Before pointer assignment"]
gdb_continue_to_breakpoint "Before pointer assignment"
@@ -16,11 +16,11 @@
require allow_cplus_tests allow_hw_watchpoint_tests
standard_testfile .cc
if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug c++}]} {
- return -1
+ return
}
if {![runto_main]} {
return
}