From 5d2cbaa526279a02cb1b70e29246099f0b8287d0 Mon Sep 17 00:00:00 2001 From: Andrew Burgess Date: Wed, 14 Jun 2017 19:47:52 +0100 Subject: [PATCH] gdb: Fix parameter passing to mi_create_breakpoint In the test gdb.mi/mi-vla-fortran.exp the parameters passed to mi_create_breakpoint are passed in the wrong order. By good luck the tests still passes, however the wrong test name is used. All fixed in this commit. gdb/testsuite/ChangeLog: * gdb.mi/mi-vla-fortran.exp: Correct parameter passing to mi_create_breakpoint. --- gdb/testsuite/ChangeLog | 5 ++++ gdb/testsuite/gdb.mi/mi-vla-fortran.exp | 36 ++++++++++++++----------- 2 files changed, 26 insertions(+), 15 deletions(-) diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index aa3dee3a09a..b9a9f94a41a 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2017-07-13 Andrew Burgess + + * gdb.mi/mi-vla-fortran.exp: Correct parameter passing to + mi_create_breakpoint. + 2017-07-11 Iain Buclaw * gdb.dlang/demangle.exp: Update for demangling changes. diff --git a/gdb/testsuite/gdb.mi/mi-vla-fortran.exp b/gdb/testsuite/gdb.mi/mi-vla-fortran.exp index b81165e848e..7b40aba6d7f 100644 --- a/gdb/testsuite/gdb.mi/mi-vla-fortran.exp +++ b/gdb/testsuite/gdb.mi/mi-vla-fortran.exp @@ -37,9 +37,9 @@ mi_gdb_reinitialize_dir $srcdir/$subdir mi_gdb_load ${binfile} set bp_lineno [gdb_get_line_number "vla1-not-allocated"] -mi_create_breakpoint "-t vla.f90:$bp_lineno" 1 "del" "vla" \ - ".*vla.f90" $bp_lineno $hex \ - "insert breakpoint at line $bp_lineno (vla not allocated)" +mi_create_breakpoint "-t vla.f90:$bp_lineno" \ + "insert breakpoint at line $bp_lineno (vla not allocated)" \ + -number 1 -disp del -func vla ".*vla.f90" $bp_lineno $hex mi_run_cmd mi_expect_stop "breakpoint-hit" "vla" "" ".*vla.f90" "$bp_lineno" \ { "" "disp=\"del\"" } "run to breakpoint at line $bp_lineno" @@ -63,8 +63,9 @@ mi_list_array_varobj_children_with_index "vla1_not_allocated" "0" "1" \ set bp_lineno [gdb_get_line_number "vla1-allocated"] -mi_create_breakpoint "-t vla.f90:$bp_lineno" 2 "del" "vla" ".*vla.f90" \ - $bp_lineno $hex "insert breakpoint at line $bp_lineno (vla allocated)" +mi_create_breakpoint "-t vla.f90:$bp_lineno" \ + "insert breakpoint at line $bp_lineno (vla allocated)" \ + -number 2 -disp del -func vla ".*vla.f90" $bp_lineno $hex mi_run_cmd mi_expect_stop "breakpoint-hit" "vla" "" ".*vla.f90" "$bp_lineno" \ { "" "disp=\"del\"" } "run to breakpoint at line $bp_lineno" @@ -87,8 +88,9 @@ mi_list_array_varobj_children_with_index "vla1_allocated" "5" "1" \ set bp_lineno [gdb_get_line_number "vla1-filled"] -mi_create_breakpoint "-t vla.f90:$bp_lineno" 3 "del" "vla" ".*vla.f90" \ - $bp_lineno $hex "insert breakpoint at line $bp_lineno" +mi_create_breakpoint "-t vla.f90:$bp_lineno" \ + "insert breakpoint at line $bp_lineno" \ + -number 3 -disp del -func vla ".*vla.f90" $bp_lineno $hex mi_run_cmd mi_expect_stop "breakpoint-hit" "vla" "" ".*vla.f90" "$bp_lineno" \ { "" "disp=\"del\"" } "run to breakpoint at line $bp_lineno" @@ -97,8 +99,9 @@ mi_gdb_test "520-data-evaluate-expression vla1" \ set bp_lineno [gdb_get_line_number "vla1-modified"] -mi_create_breakpoint "-t vla.f90:$bp_lineno" 4 "del" "vla" ".*vla.f90" \ - $bp_lineno $hex "insert breakpoint at line $bp_lineno" +mi_create_breakpoint "-t vla.f90:$bp_lineno" \ + "insert breakpoint at line $bp_lineno" \ + -number 4 -disp del -func vla ".*vla.f90" $bp_lineno $hex mi_run_cmd mi_expect_stop "breakpoint-hit" "vla" "" ".*vla.f90" "$bp_lineno" \ { "" "disp=\"del\"" } "run to breakpoint at line $bp_lineno" @@ -113,8 +116,9 @@ mi_gdb_test "560-data-evaluate-expression vla1(4)" \ set bp_lineno [gdb_get_line_number "vla1-deallocated"] -mi_create_breakpoint "-t vla.f90:$bp_lineno" 5 "del" "vla" ".*vla.f90" \ - $bp_lineno $hex "insert breakpoint at line $bp_lineno" +mi_create_breakpoint "-t vla.f90:$bp_lineno" \ + "insert breakpoint at line $bp_lineno" \ + -number 5 -disp del -func vla ".*vla.f90" $bp_lineno $hex mi_run_cmd mi_expect_stop "breakpoint-hit" "vla" "" ".*vla.f90" "$bp_lineno" \ { "" "disp=\"del\"" } "run to breakpoint at line $bp_lineno" @@ -163,8 +167,9 @@ gdb_expect { } set bp_lineno [gdb_get_line_number "pvla2-associated"] -mi_create_breakpoint "-t vla.f90:$bp_lineno" 7 "del" "vla" ".*vla.f90" \ - $bp_lineno $hex "insert breakpoint at line $bp_lineno" +mi_create_breakpoint "-t vla.f90:$bp_lineno" \ + "insert breakpoint at line $bp_lineno" \ + -number 7 -disp del -func vla ".*vla.f90" $bp_lineno $hex mi_run_cmd mi_expect_stop "breakpoint-hit" "vla" "" ".*vla.f90" "$bp_lineno" \ { "" "disp=\"del\"" } "run to breakpoint at line $bp_lineno" @@ -186,8 +191,9 @@ mi_gdb_test "593-var-evaluate-expression pvla2_associated" \ set bp_lineno [gdb_get_line_number "pvla2-set-to-null"] -mi_create_breakpoint "-t vla.f90:$bp_lineno" 8 "del" "vla" ".*vla.f90" \ - $bp_lineno $hex "insert breakpoint at line $bp_lineno" +mi_create_breakpoint "-t vla.f90:$bp_lineno" \ + "insert breakpoint at line $bp_lineno" \ + -number 8 -disp del -func vla ".*vla.f90" $bp_lineno $hex mi_run_cmd mi_expect_stop "breakpoint-hit" "vla" "" ".*vla.f90" "$bp_lineno" \ { "" "disp=\"del\"" } "run to breakpoint at line $bp_lineno" -- 2.30.2