]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
gdb/testsuite/
authorNathan Sidwell <nathan@codesourcery.com>
Fri, 9 Jun 2006 20:01:39 +0000 (20:01 +0000)
committerNathan Sidwell <nathan@codesourcery.com>
Fri, 9 Jun 2006 20:01:39 +0000 (20:01 +0000)
* gdb.base/break.c: Add breakpoint 10a marker.
* gdb.base/break.exp: Check breakpoint on }

ChangeLog.csl
gdb/testsuite/gdb.base/break.c
gdb/testsuite/gdb.base/break.exp

index 5e41d6793b0ffc0bb4458219931508656001293b..ce94383132dd99ee6676b1fbc3b646917d66fe87 100644 (file)
@@ -1,5 +1,9 @@
 2006-06-09  Nathan Sidwell  <nathan@codesourcery.com>
 
+       gdb/testsuite/
+       * gdb.base/break.c: Add breakpoint 10a marker.
+       * gdb.base/break.exp: Check breakpoint on }
+
        gdb/
        * m68k-tdep.c (m68k_frame_align): New.
        (m68k_push_dummy_call): Don't align here.
index bf398fcca91ac8603d81d8526515f94eb43fae87..db8dbdf8145085f8959bf96e24c5386eac03e907 100644 (file)
@@ -99,7 +99,7 @@ char *argv[], **envp;
     marker4 (177601976L);
     argc = (argc == 12345); /* This is silly, but we can step off of it */ /* set breakpoint 2 here */
     return argc;  /* set breakpoint 10 here */
-}
+} /* set breakpoint 10a here */
 
 #ifdef PROTOTYPES
 int factorial (int value)
index 4a704fbc6d98da97105680272e8ccebe5715e1cd..8ba761a28e8158ff3ad6f5531105fd4bd231395d 100644 (file)
@@ -262,6 +262,17 @@ gdb_test "step" \
     ".*Breakpoint \[0-9\]+, main \\(argc=.*, argv=.*, envp=.*\\) at .*$srcfile:$bp_location10.*$bp_location10\[\t \]+return argc;.*breakpoint 10 here.*" \
     "step onto breakpoint"
 
+# Check to see if breakpoint can be set on ending brace of function
+set bp_location10a [gdb_get_line_number "set breakpoint 10a here"]
+
+gdb_test "break $bp_location10a" \
+    "Breakpoint.*at.* file .*$srcfile, line $bp_location10a\\." \
+    "setting breakpoint at }"
+
+gdb_test "continue" \
+    ".*Breakpoint \[0-9\]+, main \\(argc=.*, argv=.*, envp=.*\\) at .*$srcfile:$bp_location10a.*$bp_location10a\[\t \]+}.*breakpoint 10a here.*" \
+    "continue to breakpoint at }"
+
 #
 # delete all breakpoints so we can start over, course this can be a test too
 #