diff options
Diffstat (limited to 'gdb/testsuite/lib')
-rw-r--r-- | gdb/testsuite/lib/gdb.exp | 2 | ||||
-rw-r--r-- | gdb/testsuite/lib/mi-support.exp | 16 |
2 files changed, 14 insertions, 4 deletions
diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp index 608469953bf..4c9675f255f 100644 --- a/gdb/testsuite/lib/gdb.exp +++ b/gdb/testsuite/lib/gdb.exp @@ -689,7 +689,7 @@ proc runto { function args } { # If you don't want that, use gdb_start_cmd. proc runto_main { } { - return [runto main no-message] + return [runto main no-message qualified] } ### Continue, and expect to hit a breakpoint. diff --git a/gdb/testsuite/lib/mi-support.exp b/gdb/testsuite/lib/mi-support.exp index 732aed27b27..ea59288443e 100644 --- a/gdb/testsuite/lib/mi-support.exp +++ b/gdb/testsuite/lib/mi-support.exp @@ -1055,8 +1055,12 @@ proc mi_run_to_main { } { # It returns: # -1 if test suppressed, failed, timedout # 0 if test passed +# +# Supported options: +# +# -qualified -- pass --qualified to -break-insert -proc mi_runto_helper {func run_or_continue} { +proc mi_runto_helper {func run_or_continue args} { global suppress_flag if { $suppress_flag } { return -1 @@ -1065,10 +1069,16 @@ proc mi_runto_helper {func run_or_continue} { global mi_gdb_prompt expect_out global hex decimal fullname_syntax + parse_args {{qualified}} + set test "mi runto $func" set bp [mi_make_breakpoint -type breakpoint -disp del \ -func $func\(\\\(.*\\\)\)?] - mi_gdb_test "200-break-insert -t $func" "200\\^done,$bp" \ + set extra_opts "" + if {$qualified} { + append extra_opts "--qualified" + } + mi_gdb_test "200-break-insert $extra_opts -t $func" "200\\^done,$bp" \ "breakpoint at $func" if {$run_or_continue == "run"} { @@ -1089,7 +1099,7 @@ proc mi_runto {func} { # Just like runto_main but works with the MI interface. proc mi_runto_main {} { - return [mi_runto_helper "main" "run"] + return [mi_runto_helper "main" "run" -qualified] } # Next to the next statement |