[patch/testsuite/mi] mi*-*.exp: use gdb_get_line_number

Michael Chastain mec.gnu@mindspring.com
Sat Aug 14 10:13:00 GMT 2004


This patch updates more mi*-*.exp files to use gdb_get_line_number.
This gets every file which uses basics.c.

Some test names changed:

  Old Test Names

    gdb.mi/mi-cli.exp: -break-insert -t basics.c:35
    gdb.mi/mi-cli.exp: -exec-continue to line 35
    gdb.mi/mi-cli.exp: -exec-next to line 37
    gdb.mi/mi-cli.exp: -interpreter-exec console "list" at basics.c:37
    gdb.mi/mi-simplerun.exp: insert breakpoint at basics.c:15 (callee3)
    gdb.mi/mi-simplerun.exp: insert breakpoint at "<fullfilename>":6 (callee4)

  New Test Names

    gdb.mi/mi-cli.exp: -break-insert -t basics.c:$line_main_hello
    gdb.mi/mi-cli.exp: -exec-continue to line $line_main_hello
    gdb.mi/mi-cli.exp: -exec-next to line $line_main_return
    gdb.mi/mi-cli.exp: -interpreter-exec console "list" at basics.c:$line_main_return
    gdb.mi/mi-simplerun.exp: insert breakpoint at basics.c:$line_callee3_head
    gdb.mi/mi-simplerun.exp: insert breakpoint at "<fullfilename>":$line_callee4_head

And similarly for mi2-cli.exp and mi2-simplerun.exp.

In addition to the mechanical changes, there were a couple of squibs.

In mi-file.exp and mi2-file.exp, one test depends on the default line
number in a source file.  That line number is the first line of main
minus $lines_to_list plus 1.  I added a comment to explain the
calculation.

In mi-stepi.exp and mi2-stepi.exp, several tests use a line number
with a wildcard in it:

  ... line=\"3.\" ...
  
I replaced that with an explicit range test: 

  ... (\[0-9\]+) ...
  set line $expect_out(1,string)
  if { $line >= $line_main_body && $line <= $line_main_hello } ...

I tested this by making three test runs with all of gdb.mi: the vanilla
"before" run; and then an "after" run with the same basics.c; and then
an "after" run with extra lines at the beginning of basics.c.  As usual,
my test bed was: native i686-pc-linux-gnu, gcc 2.95.3 3.3.4 3.4.1,
dwarf-2 and stabs+.

This patch was pre-approved by Andrew.  I'll give it 24 hours in
case anyone wants to discuss it, and then I'll commit it.

2004-08-14  Michael Chastain  <mec.gnu@mindspring.com>

	* gdb.mi/mi-cli.exp: Use gdb_get_line_number.  Remove reference
	to bug-gnu@prep.ai.mit.edu.
	* gdb.mi/mi-disassemble.exp: Likewise.
	* gdb.mi/mi-eval.exp: Likewise.
	* gdb.mi/mi-file.exp: Likewise.  Also, add comment about the
	default line number.
	* gdb.mi/mi-return.exp: Likewise.
	* gdb.mi/mi-simplerun.exp: Likewise.
	* gdb.mi/mi-stack.exp: Likewise.
	* gdb.mi/mi-stepi.exp: Likewise.  Also, replace wildcarded line
	number with explicit range test.
	* gdb.mi/mi-watch.exp: Likewise.
	* gdb.mi/mi2-break.exp: Likewise.
	* gdb.mi/mi2-cli.exp: Likewise.
	* gdb.mi/mi2-disassemble.exp: Likewise.
	* gdb.mi/mi2-eval.exp: Likewise.
	* gdb.mi/mi2-file.exp: Likewise.  Also, add comment about the
	default line number.
	* gdb.mi/mi2-return.exp: Likewise.
	* gdb.mi/mi2-simplerun.exp: Likewise.
	* gdb.mi/mi2-stack.exp: Likewise.
	* gdb.mi/mi2-stepi.exp: Likewise.  Also, replace wildcarded line
	number with explicit range test.
	* gdb.mi/mi2-watch.exp: Likewise.

Index: mi-cli.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi-cli.exp,v
retrieving revision 1.2
diff -u -r1.2 mi-cli.exp
--- mi-cli.exp	6 Feb 2003 01:22:06 -0000	1.2
+++ mi-cli.exp	14 Aug 2004 09:38:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 2002, 2003 Free Software Foundation, Inc.
+# Copyright 2002, 2003, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 # This file tests that GDB's console can be accessed via the MI.
 # Specifically, we are testing the "interpreter-exec" command and that
 # the commands that are executed via this command are properly executed.
@@ -67,6 +64,11 @@
 
 mi_run_to_main
 
+set line_main_head   [gdb_get_line_number "main ("]
+set line_main_body   [expr $line_main_head + 2]
+set line_main_hello  [gdb_get_line_number "Hello, World!"]
+set line_main_return [expr $line_main_hello + 2]
+
 mi_gdb_test "-interpreter-exec console \"set args foobar\"" \
   {\^done} \
   "-interpreter-exec console \"set args foobar\""
@@ -91,8 +93,9 @@
   {\^done} \
   "-interpreter-exec console \"set listsize 1\""
 
+# {.*\~"32[ \t(\\t)]*callee1.*\\n".*\^done }
 mi_gdb_test "-interpreter-exec console \"list\"" \
-  {.*\~"32[ \t(\\t)]*callee1.*\\n".*\^done} \
+  ".*\~\"$line_main_body\[\\\\t \]*callee1.*;\\\\n\".*\\^done" \
   "-interpreter-exec console \"list\""
 
 # # NOTE: cagney/2003-02-03: Not yet.
@@ -150,43 +153,43 @@
   "-stack-select-frame 0"
 
 # NOTE: cagney/2003-02-03: Not yet.
-# mi_gdb_test "-break-insert -t basics.c:35" \
+# mi_gdb_test "-break-insert -t basics.c:$line_main_hello" \
 #   {.*=breakpoint-create,number="3".*\^done} \
-#   "-break-insert -t basics.c:35"
-mi_gdb_test "600-break-insert -t basics.c:35" \
+#   "-break-insert -t basics.c:\$line_main_hello"
+mi_gdb_test "600-break-insert -t basics.c:$line_main_hello" \
 	{600\^done,bkpt=.number="3",type="breakpoint".*\}} \
-	"-break-insert -t basics.c:35"
+	"-break-insert -t basics.c:\$line_main_hello"
 
 # mi_gdb_test "-exec-continue" \
-#   {.*\*stopped.*,file=".*basics.c",line="35"\}} \
-#   "-exec-continue to line 35"
+#   {.*\*stopped.*,file=".*basics.c",line="$line_main_hello"\}} \
+#   "-exec-continue to line \$line_main_hello"
 send_gdb "700-exec-continue\n"
 gdb_expect {
-    -re "700\\^running\[\r\n\]+$mi_gdb_prompt.*\\*stopped.*,file=.*basics.c.,line=.35.*$mi_gdb_prompt$" {
-	pass "-exec-continue to line 35"
+    -re "700\\^running\[\r\n\]+$mi_gdb_prompt.*\\*stopped.*,file=.*basics.c.,line=.$line_main_hello.*$mi_gdb_prompt$" {
+	pass "-exec-continue to line \$line_main_hello"
     }
     timeout {
-	fail "-exec-continue to line 35"
+	fail "-exec-continue to line \$line_main_hello"
     }
 }
 
 # NOTE: cagney/2003-02-03: Not yet.
 # mi_gdb_test "-exec-next" \
-#   {.*\*stopped,reason="end-stepping-range",.*,file=".*basics.c",line="37"\}} \
-#   "-exec-next to line 37"
+#   {.*\*stopped,reason="end-stepping-range",.*,file=".*basics.c",line="$line_main_return"\}} \
+#   "-exec-next to line \$line_main_return"
 send_gdb "800-exec-next\n"
 gdb_expect {
-    -re "800\\^running\[\r\n\]+$mi_gdb_prompt.*\\*stopped,reason=.end-stepping-range.*,file=.*basics.c.,line=.37.*$mi_gdb_prompt$" {
-	pass "-exec-next to line 37"
+    -re "800\\^running\[\r\n\]+$mi_gdb_prompt.*\\*stopped,reason=.end-stepping-range.*,file=.*basics.c.,line=.$line_main_return.*$mi_gdb_prompt$" {
+	pass "-exec-next to line \$line_main_return"
     }
     timeout {
-	fail "-exec-next to line 37"
+	fail "-exec-next to line \$line_main_return"
     }
 }
 
 mi_gdb_test "-interpreter-exec console \"list\"" \
-  {\~"37[ \t(\\t)]*return 0;\\n".*\^done} \
-  "-interpreter-exec console \"list\" at basics.c:37"
+  "\~\"$line_main_return\[\\\\t ]*return 0;\\\\n\".*\\^done" \
+  "-interpreter-exec console \"list\" at basics.c:\$line_main_return"
 
 mi_gdb_test "-interpreter-exec console \"help set args\"" \
   {\~"Set argument list to give program being debugged when it is started\.\\nFollow this command with any number of args, to be passed to the program\.".*\^done} \
Index: mi-disassemble.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi-disassemble.exp,v
retrieving revision 1.12
diff -u -r1.12 mi-disassemble.exp
--- mi-disassemble.exp	9 Aug 2004 16:32:44 -0000	1.12
+++ mi-disassemble.exp	14 Aug 2004 09:38:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+# Copyright 1999, 2000, 2001, 2002, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 #
 # Test Machine interface (MI) operations for disassembly.
 #
@@ -48,17 +45,20 @@
     global hex
     global decimal
 
+    set line_main_head [gdb_get_line_number "main ("]
+    set line_main_body [expr $line_main_head + 2]
+
     # Test disassembly more only for the current function.
     # Tests:
     # -data-disassemble -s $pc -e "$pc+8" -- 0
-    # -data-disassembly -f basics.c -l 32 -- 0
+    # -data-disassembly -f basics.c -l $line_main_body -- 0
 
     mi_gdb_test "print/x \$pc" "" ""
     mi_gdb_test "111-data-disassemble -s \$pc -e \"\$pc + 12\" -- 0" \
 	    "111\\^done,asm_insns=\\\[\{address=\"$hex\",func-name=\"main\",offset=\"$decimal\",inst=\".*\"\},\{address=\"$hex\",func-name=\"main\",offset=\"$decimal\",inst=\".*\"\}.*\]" \
              "data-disassemble from pc to pc+12 assembly only"
 
-    mi_gdb_test "222-data-disassemble  -f basics.c -l 32 -- 0" \
+    mi_gdb_test "222-data-disassemble  -f basics.c -l $line_main_body -- 0" \
 	    "222\\^done,asm_insns=\\\[\{address=\"$hex\",func-name=\"main\",offset=\"0\",inst=\".*\"\},.*,\{address=\"$hex\",func-name=\"main\",offset=\"$decimal\",inst=\".*\"\}\\\]" \
               "data-disassemble file & line, assembly only"
 }
@@ -68,22 +68,25 @@
     global hex
     global decimal
 
+    set line_main_head [gdb_get_line_number "main ("]
+    set line_main_body [expr $line_main_head + 2]
+
     # Test disassembly more only for the current function.
     # Tests:
-    # -data-disassembly -f basics.c -l 32 -n 20 -- 0
-    # -data-disassembly -f basics.c -l 32 -n 0 -- 0
-    # -data-disassembly -f basics.c -l 32 -n 50 -- 0
+    # -data-disassembly -f basics.c -l $line_main_body -n 20 -- 0
+    # -data-disassembly -f basics.c -l $line_main_body -n 0 -- 0
+    # -data-disassembly -f basics.c -l $line_main_body -n 50 -- 0
 
     mi_gdb_test "print/x \$pc" "" ""
-    mi_gdb_test "222-data-disassemble  -f basics.c -l 32 -n 20 -- 0" \
+    mi_gdb_test "222-data-disassemble  -f basics.c -l $line_main_body -n 20 -- 0" \
 	    "222\\^done,asm_insns=\\\[\{address=\"$hex\",func-name=\"main\",offset=\"0\",inst=\".*\"\},.*,\{address=\"$hex\",func-name=\"main\",offset=\"$decimal\",inst=\".*\"\}\\\]" \
               "data-disassemble file, line, number assembly only"
 
-    mi_gdb_test "222-data-disassemble  -f basics.c -l 32 -n 0 -- 0" \
+    mi_gdb_test "222-data-disassemble  -f basics.c -l $line_main_body -n 0 -- 0" \
 	    "222\\^done,asm_insns=\\\[\\\]" \
               "data-disassemble file, line, number (zero lines) assembly only"
 
-    mi_gdb_test "222-data-disassemble  -f basics.c -l 32 -n 50 -- 0" \
+    mi_gdb_test "222-data-disassemble  -f basics.c -l $line_main_body -n 50 -- 0" \
 	    "222\\^done,asm_insns=\\\[\{address=\"$hex\",func-name=\"main\",offset=\"0\",inst=\".*\"\},.*,\{address=\"$hex\",func-name=\"main\",offset=\"$decimal\",inst=\".*\"\}\\\]" \
               "data-disassemble file, line, number (more than main lines) assembly only"
 }
@@ -94,13 +97,16 @@
     global hex
     global decimal
 
+    set line_callee2_head       [gdb_get_line_number "callee2 ("]
+    set line_callee2_open_brace [expr $line_callee2_head + 1]
+
     # Test disassembly more only for the current function.
     # Tests:
-    # -data-disassembly -f basics.c -l 21 -- 1
+    # -data-disassembly -f basics.c -l $line_callee2_open_brace -- 1
     # -data-disassembly -s $pc -e "$pc+8" -- 1
 
-    mi_gdb_test "002-data-disassemble -f basics.c -l 21 -- 1" \
-	    "002\\^done,asm_insns=\\\[src_and_asm_line=\{line=\"21\",file=\".*basics.c\",line_asm_insn=\\\[\{address=\"$hex\",func-name=\"callee2\",offset=\"0\",inst=\".*\"\}.*\\\]\}.*,src_and_asm_line=\{line=\"$decimal\",file=\".*basics.c\",line_asm_insn=\\\[.*\{address=\"$hex\",func-name=\"callee2\",offset=\"$decimal\",inst=\".*\"\}\\\]\}\\\]" \
+    mi_gdb_test "002-data-disassemble -f basics.c -l $line_callee2_open_brace -- 1" \
+	    "002\\^done,asm_insns=\\\[src_and_asm_line=\{line=\"$line_callee2_open_brace\",file=\".*basics.c\",line_asm_insn=\\\[\{address=\"$hex\",func-name=\"callee2\",offset=\"0\",inst=\".*\"\}.*\\\]\}.*,src_and_asm_line=\{line=\"$decimal\",file=\".*basics.c\",line_asm_insn=\\\[.*\{address=\"$hex\",func-name=\"callee2\",offset=\"$decimal\",inst=\".*\"\}\\\]\}\\\]" \
              "data-disassemble file, line assembly mixed"
 
     #
@@ -118,22 +124,26 @@
     global hex
     global decimal
 
+    set line_main_head       [gdb_get_line_number "main ("]
+    set line_main_open_brace [expr $line_main_head + 1]
+    set line_main_body       [expr $line_main_head + 2]
+
     # Test disassembly more only for the current function.
     # Tests:
-    # -data-disassembly -f basics.c -l 32 -n 20 -- 1
-    # -data-disassembly -f basics.c -l 32 -n 0 -- 1
-    # -data-disassembly -f basics.c -l 32 -n 50 -- 1
+    # -data-disassembly -f basics.c -l $line_main_body -n 20 -- 1
+    # -data-disassembly -f basics.c -l $line_main_body -n 0 -- 1
+    # -data-disassembly -f basics.c -l $line_main_body -n 50 -- 1
 
     mi_gdb_test "print/x \$pc" "" ""
-    mi_gdb_test "222-data-disassemble  -f basics.c -l 32 -n 20 -- 1" \
+    mi_gdb_test "222-data-disassemble  -f basics.c -l $line_main_body -n 20 -- 1" \
 	    "222\\^done,asm_insns=\\\[src_and_asm_line=\{line=\"$decimal\",file=\".*basics.c\",line_asm_insn=\\\[\{address=\"$hex\",func-name=\"main\",offset=\"0\",inst=\".*\"\},.*,\{address=\"$hex\",func-name=\"main\",offset=\"$decimal\",inst=\".*\"\}\\\]\}\]" \
               "data-disassemble file, line, number assembly mixed"
 
-    mi_gdb_test "222-data-disassemble  -f basics.c -l 32 -n 0 -- 1" \
-	    "222\\^done,asm_insns=\\\[src_and_asm_line=\{line=\"31\",file=\".*basics.c\",line_asm_insn=\\\[\\\]\}\\\]" \
+    mi_gdb_test "222-data-disassemble  -f basics.c -l $line_main_body -n 0 -- 1" \
+	    "222\\^done,asm_insns=\\\[src_and_asm_line=\{line=\"$line_main_open_brace\",file=\".*basics.c\",line_asm_insn=\\\[\\\]\}\\\]" \
               "data-disassemble file, line, number (zero lines) assembly mixed"
 
-    mi_gdb_test "222-data-disassemble  -f basics.c -l 32 -n 50 -- 1" \
+    mi_gdb_test "222-data-disassemble  -f basics.c -l $line_main_body -n 50 -- 1" \
 	    "222\\^done,asm_insns=\\\[src_and_asm_line=\{line=\"$decimal\",file=\".*basics.c\",line_asm_insn=\\\[\{address=\"$hex\",func-name=\"main\",offset=\"0\",inst=\".*\"\}.*,\{address=\"$hex\",func-name=\"main\",offset=\"$decimal\",inst=\".*\"\}\\\]\}\]" \
               "data-disassemble file, line, number (more than main lines) assembly mixed"
 }
@@ -142,6 +152,9 @@
     global mi_gdb_prompt
     global hex
 
+    set line_main_head [gdb_get_line_number "main ("]
+    set line_main_body [expr $line_main_head + 2]
+
     # Test that bogus input to disassembly command is rejected.
     # Tests:
     # -data-disassembly -f foo -l abc -n 0 -- 0
@@ -161,7 +174,7 @@
              "456\\^error,msg=\"mi_cmd_disassemble: Usage: \\( .-f filename -l linenum .-n howmany.. | .-s startaddr -e endaddr.\\) .--. mixed_mode.\"" \
              "data-disassemble mix different args"
 
-    mi_gdb_test "789-data-disassemble -f basics.c -l 32 -- 9" \
+    mi_gdb_test "789-data-disassemble -f basics.c -l $line_main_body -- 9" \
              "789\\^error,msg=\"mi_cmd_disassemble: Mixed_mode argument must be 0 or 1.\"" \
              "data-disassemble wrong mode arg"
 
Index: mi-eval.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi-eval.exp,v
retrieving revision 1.8
diff -u -r1.8 mi-eval.exp
--- mi-eval.exp	9 Aug 2004 16:32:44 -0000	1.8
+++ mi-eval.exp	14 Aug 2004 09:38:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+# Copyright 1999, 2000, 2001, 2002, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 #
 # Test essential Machine interface (MI) operations
 #
@@ -46,8 +43,11 @@
 mi_gdb_reinitialize_dir $srcdir/$subdir
 mi_gdb_load ${binfile}
 
+set line_callee4_head [gdb_get_line_number "callee4 ("]
+set line_callee4_body [expr $line_callee4_head + 2]
+
 mi_runto callee4
-mi_next_to "callee4" "" "basics.c" "9" "next at callee4"
+mi_next_to "callee4" "" "basics.c" [expr $line_callee4_body + 1] "next at callee4"
 
 mi_gdb_test "211-data-evaluate-expression A" "211\\^done,value=\"1\"" "eval A"
 
Index: mi-file.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi-file.exp,v
retrieving revision 1.3
diff -u -r1.3 mi-file.exp
--- mi-file.exp	9 Aug 2004 16:32:44 -0000	1.3
+++ mi-file.exp	14 Aug 2004 09:38:08 -0000
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 #
 # Test essential Machine interface (MI) operations
 #
@@ -54,8 +51,19 @@
     set srcfilepath [string_to_regexp ${srcdir}/${subdir}/${srcfile}]
 
     # get the path and absolute path to the current executable
+    #
+    # In gdb 6.2 (at least), the default line number is set by
+    # select_source_symtab to the first line of "main" minus
+    # the value of "lines_to_list" (which defaults to 10) plus one.
+    # --chastain 2004-08-13
+
+    set line_main_head [gdb_get_line_number "main ("]
+    set line_main_body [expr $line_main_head + 2]
+    set gdb_lines_to_list 10
+    set line_default [expr $line_main_body - $gdb_lines_to_list + 1]
+
     mi_gdb_test "111-file-list-exec-source-file" \
-	    "111\\\^done,line=\"23\",file=\"${srcfilepath}\",fullname=\"/.*/${srcfile}\"" \
+	    "111\\\^done,line=\"$line_default\",file=\"${srcfilepath}\",fullname=\"/.*/${srcfile}\"" \
                "request path info of current source file (${srcfile})"
 }
 
Index: mi-return.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi-return.exp,v
retrieving revision 1.10
diff -u -r1.10 mi-return.exp
--- mi-return.exp	9 Aug 2004 16:32:44 -0000	1.10
+++ mi-return.exp	14 Aug 2004 09:38:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+# Copyright 1999, 2000, 2001, 2002, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 # Test Machine interface (MI) operations 
 # Verify that, using the MI, we can run a simple program and perform
 # exec-return.  
@@ -51,9 +48,12 @@
     global mi_gdb_prompt
     global hex
 
+    set line_callee3_head         [gdb_get_line_number "callee3 ("]
+    set line_callee3_close_brace  [expr $line_callee3_head + 3]
+
     send_gdb "111-exec-return\n"
     gdb_expect {
-	-re "111\\^done,frame=\{level=\"0\",addr=\"$hex\",func=\"callee3\",args=\\\[.*\\\],file=\".*basics.c\",line=\"18\"\}\r\n$mi_gdb_prompt$" {pass "return from callee4 now"}
+	-re "111\\^done,frame=\{level=\"0\",addr=\"$hex\",func=\"callee3\",args=\\\[.*\\\],file=\".*basics.c\",line=\"$line_callee3_close_brace\"\}\r\n$mi_gdb_prompt$" {pass "return from callee4 now"}
 	-re ".*\r\n$mi_gdb_prompt$" { fail "return from callee4 now" }
 	timeout { fail "return from callee4 now (timeout)"
 	}
Index: mi-simplerun.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi-simplerun.exp,v
retrieving revision 1.11
diff -u -r1.11 mi-simplerun.exp
--- mi-simplerun.exp	9 Aug 2004 16:32:44 -0000	1.11
+++ mi-simplerun.exp	14 Aug 2004 09:38:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+# Copyright 1999, 2000, 2001, 2002, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 #
 # Test essential Machine interface (MI) operations
 #
@@ -53,6 +50,13 @@
     global srcfile
     global hex
 
+    set line_callee4_head  [gdb_get_line_number "callee4 ("]
+    set line_callee3_head  [gdb_get_line_number "callee3 ("]
+    set line_callee2_head  [gdb_get_line_number "callee2 ("]
+    set line_callee2_body  [expr $line_callee2_head + 2]
+    set line_main_head     [gdb_get_line_number "main ("]
+    set line_main_body     [expr $line_main_head + 2]
+
     # Insert some breakpoints and list them
     # Also, disable some so they do not interfere with other tests
     # Tests:
@@ -62,23 +66,23 @@
     # -break-info
 
     mi_gdb_test "200-break-insert main" \
-             "200\\^done,bkpt=\{number=\"1\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"32\",times=\"0\"\}" \
+             "200\\^done,bkpt=\{number=\"1\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"$line_main_body\",times=\"0\"\}" \
              "break-insert operation"
 
     mi_gdb_test "201-break-insert basics.c:callee2" \
-             "201\\^done,bkpt=\{number=\"2\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee2\",file=\".*basics.c\",line=\"22\",times=\"0\"\}" \
+             "201\\^done,bkpt=\{number=\"2\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee2\",file=\".*basics.c\",line=\"$line_callee2_body\",times=\"0\"\}" \
              "insert breakpoint at basics.c:callee2"
 
-    mi_gdb_test "202-break-insert basics.c:15" \
-             "202\\^done,bkpt=\{number=\"3\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee3\",file=\".*basics.c\",line=\"15\",times=\"0\"\}" \
-             "insert breakpoint at basics.c:15 (callee3)"
-
-    mi_gdb_test "203-break-insert \"\\\"${srcfile}\\\":6\"" \
-             "203\\^done,bkpt=\{number=\"4\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"6\",times=\"0\"\}" \
-             "insert breakpoint at \"<fullfilename>\":6 (callee4)"
+    mi_gdb_test "202-break-insert basics.c:$line_callee3_head" \
+             "202\\^done,bkpt=\{number=\"3\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee3\",file=\".*basics.c\",line=\"$line_callee3_head\",times=\"0\"\}" \
+             "insert breakpoint at basics.c:\$line_callee3_head"
+
+    mi_gdb_test "203-break-insert \"\\\"${srcfile}\\\":$line_callee4_head\"" \
+             "203\\^done,bkpt=\{number=\"4\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"$line_callee4_head\",times=\"0\"\}" \
+             "insert breakpoint at \"<fullfilename>\":\$line_callee4_head"
 
     mi_gdb_test "204-break-list" \
-	    "204\\^done,BreakpointTable=\{.*,hdr=\\\[.*\\\],body=\\\[bkpt=\{number=\"1\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"32\",times=\"0\"\},.*\}\\\]\}" \
+	    "204\\^done,BreakpointTable=\{.*,hdr=\\\[.*\\\],body=\\\[bkpt=\{number=\"1\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"$line_main_body\",times=\"0\"\},.*\}\\\]\}" \
                 "list of breakpoints"
 
     mi_gdb_test "205-break-disable 2 3 4" \
@@ -94,6 +98,9 @@
     global mi_gdb_prompt
     global hex
 
+    set line_main_head     [gdb_get_line_number "main ("]
+    set line_main_body     [expr $line_main_head + 2]
+
     # Run the program without args, then specify srgs and rerun the program
     # Tests:
     # -exec-run
@@ -104,7 +111,7 @@
     # The following is equivalent to a send_gdb "000-exec-run\n"
     mi_run_cmd
     gdb_expect {
-	-re "000\\*stopped,reason=\"breakpoint-hit\",bkptno=\"1\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"32\"\}\r\n$mi_gdb_prompt$" {
+	-re "000\\*stopped,reason=\"breakpoint-hit\",bkptno=\"1\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"$line_main_body\"\}\r\n$mi_gdb_prompt$" {
 	    pass "run to main"
 	}
 	-re ".*$mi_gdb_prompt$" {
@@ -120,6 +127,15 @@
     global mi_gdb_prompt
     global hex
 
+    set line_callee4_head         [gdb_get_line_number "callee4 ("]
+    set line_callee4_body         [expr $line_callee4_head + 2]
+    set line_callee3_head         [gdb_get_line_number "callee3 ("]
+    set line_callee3_close_brace  [expr $line_callee3_head + 3]
+    set line_callee1_head         [gdb_get_line_number "callee1 ("]
+    set line_callee1_body         [expr $line_callee1_head + 2]
+    set line_main_head            [gdb_get_line_number "main ("]
+    set line_main_body            [expr $line_main_head + 2]
+
     # Continue execution until a breakpoint is reached, step into calls, verifying
     # if the arguments are correctly shown, continue to the end of a called
     # function, step over a call (next).
@@ -129,24 +145,24 @@
     # -exec-step
     # -exec-finish
 
-    mi_next_to "main" "" "basics.c" "33" "next at main"
+    mi_next_to "main" "" "basics.c" [expr $line_main_body + 1] "next at main"
 
     # FIXME: A string argument is not printed right; should be fixed and
     #        we should look for the right thing here.
     # NOTE: The ``\\\\\"'' is for \".
     mi_step_to "callee1" \
 	"\{name=\"intarg\",value=\"2\"\},\{name=\"strarg\",value=\"$hex \\\\\"A string argument\.\\\\\"\"\},\{name=\"fltarg\",value=\"3.5\"\}" \
-	"basics.c" "27" "step at main"
+	"basics.c" "$line_callee1_body" "step at main"
 
     # FIXME: A string argument is not printed right; should be fixed and
     #        we should look for the right thing here.
     mi_execute_to "exec-step 3" "end-stepping-range" "callee4" "" \
-	"basics.c" "8" "" "step to callee4"
+	"basics.c" $line_callee4_body "" "step to callee4"
 
     # FIXME: A string argument is not printed right; should be fixed and
     #        we should look for the right thing here.
     # NOTE: The ``.'' is part of ``gdb-result-var="$1"''
-    mi_finish_to "callee3" ".*" "basics.c" "18" ".1" "0" "exec-finish"
+    mi_finish_to "callee3" ".*" "basics.c" $line_callee3_close_brace ".1" "0" "exec-finish"
 }
 
 proc test_controlling_breakpoints {} {
Index: mi-stack.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi-stack.exp,v
retrieving revision 1.13
diff -u -r1.13 mi-stack.exp
--- mi-stack.exp	9 Aug 2004 16:32:44 -0000	1.13
+++ mi-stack.exp	14 Aug 2004 09:38:08 -0000
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 #
 # Test essential Machine interface (MI) operations
 #
@@ -50,6 +47,9 @@
     global mi_gdb_prompt
     global hex
 
+    set line_callee4_head [gdb_get_line_number "callee4 ("]
+    set line_callee4_body [expr $line_callee4_head + 2]
+
     # Obtain a stack trace
     # Tests:
     # -stack-list-frames
@@ -57,7 +57,7 @@
     # -stack-list-frames 1 3
 
     mi_gdb_test "231-stack-list-frames" \
-	    "231\\^done,stack=\\\[frame=\{level=\"0\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"8\"\},frame=\{level=\"1\",addr=\"$hex\",func=\"callee3\",.*\},frame=\{level=\"2\",addr=\"$hex\",func=\"callee2\",.*\},frame=\{level=\"3\",addr=\"$hex\",func=\"callee1\",.*\},frame=\{level=\"4\",addr=\"$hex\",func=\"main\",.*\}\\\]" \
+	    "231\\^done,stack=\\\[frame=\{level=\"0\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"$line_callee4_body\"\},frame=\{level=\"1\",addr=\"$hex\",func=\"callee3\",.*\},frame=\{level=\"2\",addr=\"$hex\",func=\"callee2\",.*\},frame=\{level=\"3\",addr=\"$hex\",func=\"callee1\",.*\},frame=\{level=\"4\",addr=\"$hex\",func=\"main\",.*\}\\\]" \
                 "stack frame listing"
     mi_gdb_test "232-stack-list-frames 1 1" \
 	    "232\\^done,stack=\\\[frame=\{level=\"1\",addr=\"$hex\",func=\"callee3\",.*\}\\\]" \
@@ -156,10 +156,12 @@
 	    "232\\^done,locals=\\\[name=\"A\",name=\"B\",name=\"C\"\\\]" \
                 "stack locals listing 0"
 
+set line_callee4_return_0 [gdb_get_line_number "return 0;"]
+
 # step until A, B, C, have some reasonable values.
 send_gdb "-exec-next 3\n"
 gdb_expect {
-    -re "\\^running\r\n${mi_gdb_prompt}\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"callee4\",args=\\\[\\\],file=\".*basics.c\",line=\"13\"\}\r\n$mi_gdb_prompt$" {
+    -re "\\^running\r\n${mi_gdb_prompt}\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"callee4\",args=\\\[\\\],file=\".*basics.c\",line=\"$line_callee4_return_0\"\}\r\n$mi_gdb_prompt$" {
 	pass "next's in callee4"
     }
     timeout { fail "next in callee4 (timeout)" }
Index: mi-stepi.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi-stepi.exp,v
retrieving revision 1.9
diff -u -r1.9 mi-stepi.exp
--- mi-stepi.exp	9 Aug 2004 16:32:44 -0000	1.9
+++ mi-stepi.exp	14 Aug 2004 09:38:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+# Copyright 1999, 2000, 2001, 2002, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 # Test Machine interface (MI) operations 
 # Verify that, using the MI, we can run a simple program and perform
 # exec-step-instruction and exec-next-instruction.  
@@ -50,10 +47,19 @@
     global mi_gdb_prompt
     global hex
 
+    set line_main_head  [gdb_get_line_number "main ("]
+    set line_main_body  [expr $line_main_head + 2]
+    set line_main_hello [gdb_get_line_number "Hello, World!"]
+
     send_gdb "111-exec-step-instruction\n"
     gdb_expect {
-	-re "111\\^running\r\n${mi_gdb_prompt}111\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"3.\"\}\r\n$mi_gdb_prompt$" {
-	    pass "step-instruction at main"
+	-re "111\\^running\r\n${mi_gdb_prompt}111\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"(\[0-9\]+)\"\}\r\n$mi_gdb_prompt$" {
+	    set line $expect_out(1,string)
+	    if { $line >= $line_main_body && $line <= $line_main_hello } {
+		pass "step-instruction at main"
+	    } else {
+		fail "step-instruction at main"
+	    }
 	}
 	timeout {
 	    fail "step-instruction at main (timeout)"
@@ -61,8 +67,13 @@
     }
     send_gdb "222-exec-next-instruction\n"
     gdb_expect {
-	-re "222\\^running\r\n${mi_gdb_prompt}222\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"3.\"\}\r\n$mi_gdb_prompt$" {
-	    pass "next-instruction at main"
+	-re "222\\^running\r\n${mi_gdb_prompt}222\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"(\[0-9\]+)\"\}\r\n$mi_gdb_prompt$" {
+	    set line $expect_out(1,string)
+	    if { $line >= $line_main_body && $line <= $line_main_hello } {
+		pass "next-instruction at main"
+	    } else {
+		fail "next-instruction at main"
+	    }
 	}
 	timeout {
 	    fail "next-instruction at main (timeout)"
@@ -70,8 +81,13 @@
     }
     send_gdb "333-exec-next-instruction\n"
     gdb_expect {
-	-re "333\\^running\r\n${mi_gdb_prompt}333\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"3.\"\}\r\n$mi_gdb_prompt$" {
-	    pass "next-instruction at main"
+	-re "333\\^running\r\n${mi_gdb_prompt}333\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"(\[0-9\]+)\"\}\r\n$mi_gdb_prompt$" {
+	    set line $expect_out(1,string)
+	    if { $line >= $line_main_body && $line <= $line_main_hello } {
+		pass "next-instruction at main"
+	    } else {
+		fail "next-instruction at main"
+	    }
 	}
 	timeout {
 	    fail "next-instruction at main (timeout)"
Index: mi-watch.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi-watch.exp,v
retrieving revision 1.10
diff -u -r1.10 mi-watch.exp
--- mi-watch.exp	9 Aug 2004 16:32:44 -0000	1.10
+++ mi-watch.exp	14 Aug 2004 09:38:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+# Copyright 1999, 2000, 2001, 2002, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 #
 # Test essential Machine interface (MI) operations
 #
@@ -52,6 +49,9 @@
     global srcfile
     global hex
 
+    set line_callee4_head [gdb_get_line_number "callee4 ("]
+    set line_callee4_body [expr $line_callee4_head + 2]
+
     # Insert a watchpoint and list
     # Tests:
     # -break-watch C
@@ -62,7 +62,7 @@
              "break-watch operation"
 
     mi_gdb_test "222-break-list" \
-	    "222\\\^done,BreakpointTable=\{nr_rows=\".\",nr_cols=\".\",hdr=\\\[\{width=\".*\",alignment=\".*\",col_name=\"number\",colhdr=\"Num\"\}.*colhdr=\"Type\".*colhdr=\"Disp\".*colhdr=\"Enb\".*colhdr=\"Address\".*colhdr=\"What\".*\\\],body=\\\[bkpt=\{number=\"1\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"8\",times=\"1\"\},bkpt=\{number=\"2\",type=\".*watchpoint\",disp=\"keep\",enabled=\"y\",addr=\"\",what=\"C\",times=\"0\"\}\\\]\}" \
+	    "222\\\^done,BreakpointTable=\{nr_rows=\".\",nr_cols=\".\",hdr=\\\[\{width=\".*\",alignment=\".*\",col_name=\"number\",colhdr=\"Num\"\}.*colhdr=\"Type\".*colhdr=\"Disp\".*colhdr=\"Enb\".*colhdr=\"Address\".*colhdr=\"What\".*\\\],body=\\\[bkpt=\{number=\"1\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"$line_callee4_body\",times=\"1\"\},bkpt=\{number=\"2\",type=\".*watchpoint\",disp=\"keep\",enabled=\"y\",addr=\"\",what=\"C\",times=\"0\"\}\\\]\}" \
                 "list of watchpoints"
 
 }
@@ -73,17 +73,20 @@
     global srcfile
     global hex
 
+    set line_main_head [gdb_get_line_number "main ("]
+    set line_main_body [expr $line_main_head + 2]
+
     # Insert an access watchpoint and list it
     # Tests:
     # -break-watch -a A
     # -break-list
 
     mi_gdb_test "333-break-watch -a A" \
-             "333\\^done,bkpt=\{number=\"1\",addr=\"$hex\",file=\".*basics.c\",line=\"32\"\}" \
+             "333\\^done,bkpt=\{number=\"1\",addr=\"$hex\",file=\".*basics.c\",line=\"$line_main_body\"\}" \
              "break-watch -a operation"
 
     mi_gdb_test "444-break-list" \
-	    "444\\^done,BreakpointTable=\{.*,hdr=\\\[.*\\\],body=\\\[bkpt=\{number=\"3\",type=\"watchpoint\",disp=\"del\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"32\",times=\"0\"\},.*\}\\\]\}" \
+	    "444\\^done,BreakpointTable=\{.*,hdr=\\\[.*\\\],body=\\\[bkpt=\{number=\"3\",type=\"watchpoint\",disp=\"del\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"$line_main_body\",times=\"0\"\},.*\}\\\]\}" \
                 "list of watchpoints awatch"
 
     mi_gdb_test "777-break-delete 3" \
@@ -97,17 +100,20 @@
     global srcfile
     global hex
 
+    set line_main_head [gdb_get_line_number "main ("]
+    set line_main_body [expr $line_main_head + 2]
+
     # Insert a read watchpoint and list it.
     # Tests:
     # -break-insert -r B
     # -break-list
 
     mi_gdb_test "200-break-watch -r C" \
-             "200\\^done,bkpt=\{number=\"5\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"32\",times=\"0\"\}" \
+             "200\\^done,bkpt=\{number=\"5\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"$line_main_body\",times=\"0\"\}" \
              "break-insert -r operation"
 
     mi_gdb_test "300-break-list" \
-	    "300\\^done,BreakpointTable=\{.*,hdr=\\\[.*\\\],body=\\\[bkpt=\{number=\"5\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"32\",times=\"0\"\},.*\}\\\}\}" \
+	    "300\\^done,BreakpointTable=\{.*,hdr=\\\[.*\\\],body=\\\[bkpt=\{number=\"5\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"$line_main_body\",times=\"0\"\},.*\}\\\}\}" \
                 "list of breakpoints"
 
     mi_gdb_test "177-break-delete 4" \
@@ -119,6 +125,10 @@
     global mi_gdb_prompt
     global hex
 
+    set line_callee4_return_0     [gdb_get_line_number "return 0;"]
+    set line_callee3_head         [gdb_get_line_number "callee3 ("]
+    set line_callee3_close_brace  [expr $line_callee3_head + 3]
+
     # Continue execution until the watchpoint is reached,  continue again, 
     # to see the watchpoint go out of scope.
     # Does:
@@ -129,7 +139,7 @@
     gdb_expect {
       -re "222\\^running\r\n$mi_gdb_prompt" {
         gdb_expect {
-	    -re "222\\*stopped,reason=\"watchpoint-trigger\",wpt=\{number=\"2\",exp=\"C\"\},value=\{old=\".*\",new=\"3\"\},thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"callee4\",args=\\\[\\\],file=\".*basics.c\",line=\"13\"\}\r\n$mi_gdb_prompt$" {
+	    -re "222\\*stopped,reason=\"watchpoint-trigger\",wpt=\{number=\"2\",exp=\"C\"\},value=\{old=\".*\",new=\"3\"\},thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"callee4\",args=\\\[\\\],file=\".*basics.c\",line=\"$line_callee4_return_0\"\}\r\n$mi_gdb_prompt$" {
             pass "watchpoint trigger"
           }
           -re ".*$mi_gdb_prompt$" {fail "watchpoint trigger (2)"}
@@ -144,7 +154,7 @@
     gdb_expect {
       -re "223\\^running\r\n$mi_gdb_prompt" {
         gdb_expect {
-	    -re "\[\r\n\]*223\\*stopped,reason=\"watchpoint-scope\",wpnum=\"2\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"callee3\",args=\\\[.*\\\],file=\".*basics.c\",line=\"18\"\}\r\n$mi_gdb_prompt$" {
+	    -re "\[\r\n\]*223\\*stopped,reason=\"watchpoint-scope\",wpnum=\"2\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"callee3\",args=\\\[.*\\\],file=\".*basics.c\",line=\"$line_callee3_close_brace\"\}\r\n$mi_gdb_prompt$" {
             pass "wp out of scope"
           }
           -re ".*$mi_gdb_prompt$" {fail "wp out of scope (2)"}
Index: mi2-cli.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi2-cli.exp,v
retrieving revision 1.1
diff -u -r1.1 mi2-cli.exp
--- mi2-cli.exp	7 Aug 2003 17:47:42 -0000	1.1
+++ mi2-cli.exp	14 Aug 2004 09:38:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 2002, 2003 Free Software Foundation, Inc.
+# Copyright 2002, 2003, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 # This file tests that GDB's console can be accessed via the MI.
 # Specifically, we are testing the "interpreter-exec" command and that
 # the commands that are executed via this command are properly executed.
@@ -67,6 +64,11 @@
 
 mi_run_to_main
 
+set line_main_head   [gdb_get_line_number "main ("]
+set line_main_body   [expr $line_main_head + 2]
+set line_main_hello  [gdb_get_line_number "Hello, World!"]
+set line_main_return [expr $line_main_hello + 2]
+
 mi_gdb_test "-interpreter-exec console \"set args foobar\"" \
   {\^done} \
   "-interpreter-exec console \"set args foobar\""
@@ -91,8 +93,9 @@
   {\^done} \
   "-interpreter-exec console \"set listsize 1\""
 
+# {.*\~"32[ \t(\\t)]*callee1.*\\n".*\^done }
 mi_gdb_test "-interpreter-exec console \"list\"" \
-  {.*\~"32[ \t(\\t)]*callee1.*\\n".*\^done} \
+  ".*\~\"$line_main_body\[\\\\t \]*callee1.*;\\\\n\".*\\^done" \
   "-interpreter-exec console \"list\""
 
 # # NOTE: cagney/2003-02-03: Not yet.
@@ -150,43 +153,43 @@
   "-stack-select-frame 0"
 
 # NOTE: cagney/2003-02-03: Not yet.
-# mi_gdb_test "-break-insert -t basics.c:35" \
+# mi_gdb_test "-break-insert -t basics.c:$line_main_hello" \
 #   {.*=breakpoint-create,number="3".*\^done} \
-#   "-break-insert -t basics.c:35"
-mi_gdb_test "600-break-insert -t basics.c:35" \
+#   "-break-insert -t basics.c:\$line_main_hello"
+mi_gdb_test "600-break-insert -t basics.c:$line_main_hello" \
 	{600\^done,bkpt=.number="3",type="breakpoint".*\}} \
-	"-break-insert -t basics.c:35"
+	"-break-insert -t basics.c:\$line_main_hello"
 
 # mi_gdb_test "-exec-continue" \
-#   {.*\*stopped.*,file=".*basics.c",line="35"\}} \
-#   "-exec-continue to line 35"
+#   {.*\*stopped.*,file=".*basics.c",line="$line_main_hello"\}} \
+#   "-exec-continue to line \$line_main_hello"
 send_gdb "700-exec-continue\n"
 gdb_expect {
-    -re "700\\^running\[\r\n\]+$mi_gdb_prompt.*\\*stopped.*,file=.*basics.c.,line=.35.*$mi_gdb_prompt$" {
-	pass "-exec-continue to line 35"
+    -re "700\\^running\[\r\n\]+$mi_gdb_prompt.*\\*stopped.*,file=.*basics.c.,line=.$line_main_hello.*$mi_gdb_prompt$" {
+	pass "-exec-continue to line \$line_main_hello"
     }
     timeout {
-	fail "-exec-continue to line 35"
+	fail "-exec-continue to line \$line_main_hello"
     }
 }
 
 # NOTE: cagney/2003-02-03: Not yet.
 # mi_gdb_test "-exec-next" \
-#   {.*\*stopped,reason="end-stepping-range",.*,file=".*basics.c",line="37"\}} \
-#   "-exec-next to line 37"
+#   {.*\*stopped,reason="end-stepping-range",.*,file=".*basics.c",line="$line_main_return"\}} \
+#   "-exec-next to line \$line_main_return"
 send_gdb "800-exec-next\n"
 gdb_expect {
-    -re "800\\^running\[\r\n\]+$mi_gdb_prompt.*\\*stopped,reason=.end-stepping-range.*,file=.*basics.c.,line=.37.*$mi_gdb_prompt$" {
-	pass "-exec-next to line 37"
+    -re "800\\^running\[\r\n\]+$mi_gdb_prompt.*\\*stopped,reason=.end-stepping-range.*,file=.*basics.c.,line=.$line_main_return.*$mi_gdb_prompt$" {
+	pass "-exec-next to line \$line_main_return"
     }
     timeout {
-	fail "-exec-next to line 37"
+	fail "-exec-next to line \$line_main_return"
     }
 }
 
 mi_gdb_test "-interpreter-exec console \"list\"" \
-  {\~"37[ \t(\\t)]*return 0;\\n".*\^done} \
-  "-interpreter-exec console \"list\" at basics.c:37"
+  "\~\"$line_main_return\[\\\\t ]*return 0;\\\\n\".*\\^done" \
+  "-interpreter-exec console \"list\" at basics.c:\$line_main_return"
 
 mi_gdb_test "-interpreter-exec console \"help set args\"" \
   {\~"Set argument list to give program being debugged when it is started\.\\nFollow this command with any number of args, to be passed to the program\.".*\^done} \
Index: mi2-disassemble.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi2-disassemble.exp,v
retrieving revision 1.2
diff -u -r1.2 mi2-disassemble.exp
--- mi2-disassemble.exp	9 Aug 2004 22:21:54 -0000	1.2
+++ mi2-disassemble.exp	14 Aug 2004 09:38:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
+# Copyright 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 #
 # Test Machine interface (MI) operations for disassembly.
 #
@@ -48,17 +45,20 @@
     global hex
     global decimal
 
+    set line_main_head [gdb_get_line_number "main ("]
+    set line_main_body [expr $line_main_head + 2]
+
     # Test disassembly more only for the current function.
     # Tests:
     # -data-disassemble -s $pc -e "$pc+8" -- 0
-    # -data-disassembly -f basics.c -l 32 -- 0
+    # -data-disassembly -f basics.c -l $line_main_body -- 0
 
     mi_gdb_test "print/x \$pc" "" ""
     mi_gdb_test "111-data-disassemble -s \$pc -e \"\$pc + 12\" -- 0" \
 	    "111\\^done,asm_insns=\\\[\{address=\"$hex\",func-name=\"main\",offset=\"$decimal\",inst=\".*\"\},\{address=\"$hex\",func-name=\"main\",offset=\"$decimal\",inst=\".*\"\}.*\]" \
              "data-disassemble from pc to pc+12 assembly only"
 
-    mi_gdb_test "222-data-disassemble  -f basics.c -l 32 -- 0" \
+    mi_gdb_test "222-data-disassemble  -f basics.c -l $line_main_body -- 0" \
 	    "222\\^done,asm_insns=\\\[\{address=\"$hex\",func-name=\"main\",offset=\"0\",inst=\".*\"\},.*,\{address=\"$hex\",func-name=\"main\",offset=\"$decimal\",inst=\".*\"\}\\\]" \
               "data-disassemble file & line, assembly only"
 }
@@ -68,22 +68,25 @@
     global hex
     global decimal
 
+    set line_main_head [gdb_get_line_number "main ("]
+    set line_main_body [expr $line_main_head + 2]
+
     # Test disassembly more only for the current function.
     # Tests:
-    # -data-disassembly -f basics.c -l 32 -n 20 -- 0
-    # -data-disassembly -f basics.c -l 32 -n 0 -- 0
-    # -data-disassembly -f basics.c -l 32 -n 50 -- 0
+    # -data-disassembly -f basics.c -l $line_main_body -n 20 -- 0
+    # -data-disassembly -f basics.c -l $line_main_body -n 0 -- 0
+    # -data-disassembly -f basics.c -l $line_main_body -n 50 -- 0
 
     mi_gdb_test "print/x \$pc" "" ""
-    mi_gdb_test "222-data-disassemble  -f basics.c -l 32 -n 20 -- 0" \
+    mi_gdb_test "222-data-disassemble  -f basics.c -l $line_main_body -n 20 -- 0" \
 	    "222\\^done,asm_insns=\\\[\{address=\"$hex\",func-name=\"main\",offset=\"0\",inst=\".*\"\},.*,\{address=\"$hex\",func-name=\"main\",offset=\"$decimal\",inst=\".*\"\}\\\]" \
               "data-disassemble file, line, number assembly only"
 
-    mi_gdb_test "222-data-disassemble  -f basics.c -l 32 -n 0 -- 0" \
+    mi_gdb_test "222-data-disassemble  -f basics.c -l $line_main_body -n 0 -- 0" \
 	    "222\\^done,asm_insns=\\\[\\\]" \
               "data-disassemble file, line, number (zero lines) assembly only"
 
-    mi_gdb_test "222-data-disassemble  -f basics.c -l 32 -n 50 -- 0" \
+    mi_gdb_test "222-data-disassemble  -f basics.c -l $line_main_body -n 50 -- 0" \
 	    "222\\^done,asm_insns=\\\[\{address=\"$hex\",func-name=\"main\",offset=\"0\",inst=\".*\"\},.*,\{address=\"$hex\",func-name=\"main\",offset=\"$decimal\",inst=\".*\"\}\\\]" \
               "data-disassemble file, line, number (more than main lines) assembly only"
 }
@@ -94,13 +97,16 @@
     global hex
     global decimal
 
+    set line_callee2_head       [gdb_get_line_number "callee2 ("]
+    set line_callee2_open_brace [expr $line_callee2_head + 1]
+
     # Test disassembly more only for the current function.
     # Tests:
-    # -data-disassembly -f basics.c -l 21 -- 1
+    # -data-disassembly -f basics.c -l $line_callee2_open_brace -- 1
     # -data-disassembly -s $pc -e "$pc+8" -- 1
 
-    mi_gdb_test "002-data-disassemble -f basics.c -l 21 -- 1" \
-	    "002\\^done,asm_insns=\\\[src_and_asm_line=\{line=\"21\",file=\".*basics.c\",line_asm_insn=\\\[\{address=\"$hex\",func-name=\"callee2\",offset=\"0\",inst=\".*\"\}.*\\\]\}.*,src_and_asm_line=\{line=\"$decimal\",file=\".*basics.c\",line_asm_insn=\\\[.*\{address=\"$hex\",func-name=\"callee2\",offset=\"$decimal\",inst=\".*\"\}\\\]\}\\\]" \
+    mi_gdb_test "002-data-disassemble -f basics.c -l $line_callee2_open_brace -- 1" \
+	    "002\\^done,asm_insns=\\\[src_and_asm_line=\{line=\"$line_callee2_open_brace\",file=\".*basics.c\",line_asm_insn=\\\[\{address=\"$hex\",func-name=\"callee2\",offset=\"0\",inst=\".*\"\}.*\\\]\}.*,src_and_asm_line=\{line=\"$decimal\",file=\".*basics.c\",line_asm_insn=\\\[.*\{address=\"$hex\",func-name=\"callee2\",offset=\"$decimal\",inst=\".*\"\}\\\]\}\\\]" \
              "data-disassemble file, line assembly mixed"
 
     #
@@ -118,22 +124,26 @@
     global hex
     global decimal
 
+    set line_main_head       [gdb_get_line_number "main ("]
+    set line_main_open_brace [expr $line_main_head + 1]
+    set line_main_body       [expr $line_main_head + 2]
+
     # Test disassembly more only for the current function.
     # Tests:
-    # -data-disassembly -f basics.c -l 32 -n 20 -- 1
-    # -data-disassembly -f basics.c -l 32 -n 0 -- 1
-    # -data-disassembly -f basics.c -l 32 -n 50 -- 1
+    # -data-disassembly -f basics.c -l $line_main_body -n 20 -- 1
+    # -data-disassembly -f basics.c -l $line_main_body -n 0 -- 1
+    # -data-disassembly -f basics.c -l $line_main_body -n 50 -- 1
 
     mi_gdb_test "print/x \$pc" "" ""
-    mi_gdb_test "222-data-disassemble  -f basics.c -l 32 -n 20 -- 1" \
+    mi_gdb_test "222-data-disassemble  -f basics.c -l $line_main_body -n 20 -- 1" \
 	    "222\\^done,asm_insns=\\\[src_and_asm_line=\{line=\"$decimal\",file=\".*basics.c\",line_asm_insn=\\\[\{address=\"$hex\",func-name=\"main\",offset=\"0\",inst=\".*\"\},.*,\{address=\"$hex\",func-name=\"main\",offset=\"$decimal\",inst=\".*\"\}\\\]\}\]" \
               "data-disassemble file, line, number assembly mixed"
 
-    mi_gdb_test "222-data-disassemble  -f basics.c -l 32 -n 0 -- 1" \
-	    "222\\^done,asm_insns=\\\[src_and_asm_line=\{line=\"31\",file=\".*basics.c\",line_asm_insn=\\\[\\\]\}\\\]" \
+    mi_gdb_test "222-data-disassemble  -f basics.c -l $line_main_body -n 0 -- 1" \
+	    "222\\^done,asm_insns=\\\[src_and_asm_line=\{line=\"$line_main_open_brace\",file=\".*basics.c\",line_asm_insn=\\\[\\\]\}\\\]" \
               "data-disassemble file, line, number (zero lines) assembly mixed"
 
-    mi_gdb_test "222-data-disassemble  -f basics.c -l 32 -n 50 -- 1" \
+    mi_gdb_test "222-data-disassemble  -f basics.c -l $line_main_body -n 50 -- 1" \
 	    "222\\^done,asm_insns=\\\[src_and_asm_line=\{line=\"$decimal\",file=\".*basics.c\",line_asm_insn=\\\[\{address=\"$hex\",func-name=\"main\",offset=\"0\",inst=\".*\"\}.*,\{address=\"$hex\",func-name=\"main\",offset=\"$decimal\",inst=\".*\"\}\\\]\}\]" \
               "data-disassemble file, line, number (more than main lines) assembly mixed"
 }
@@ -142,6 +152,9 @@
     global mi_gdb_prompt
     global hex
 
+    set line_main_head [gdb_get_line_number "main ("]
+    set line_main_body [expr $line_main_head + 2]
+
     # Test that bogus input to disassembly command is rejected.
     # Tests:
     # -data-disassembly -f foo -l abc -n 0 -- 0
@@ -161,7 +174,7 @@
              "456\\^error,msg=\"mi_cmd_disassemble: Usage: \\( .-f filename -l linenum .-n howmany.. | .-s startaddr -e endaddr.\\) .--. mixed_mode.\"" \
              "data-disassemble mix different args"
 
-    mi_gdb_test "789-data-disassemble -f basics.c -l 32 -- 9" \
+    mi_gdb_test "789-data-disassemble -f basics.c -l $line_main_body -- 9" \
              "789\\^error,msg=\"mi_cmd_disassemble: Mixed_mode argument must be 0 or 1.\"" \
              "data-disassemble wrong mode arg"
 
Index: mi2-eval.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi2-eval.exp,v
retrieving revision 1.2
diff -u -r1.2 mi2-eval.exp
--- mi2-eval.exp	9 Aug 2004 22:21:54 -0000	1.2
+++ mi2-eval.exp	14 Aug 2004 09:38:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
+# Copyright 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 #
 # Test essential Machine interface (MI) operations
 #
@@ -46,8 +43,11 @@
 mi_gdb_reinitialize_dir $srcdir/$subdir
 mi_gdb_load ${binfile}
 
+set line_callee4_head [gdb_get_line_number "callee4 ("]
+set line_callee4_body [expr $line_callee4_head + 2]
+
 mi_runto callee4
-mi_next_to "callee4" "" "basics.c" "9" "next at callee4"
+mi_next_to "callee4" "" "basics.c" [expr $line_callee4_body + 1] "next at callee4"
 
 mi_gdb_test "211-data-evaluate-expression A" "211\\^done,value=\"1\"" "eval A"
 
Index: mi2-file.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi2-file.exp,v
retrieving revision 1.4
diff -u -r1.4 mi2-file.exp
--- mi2-file.exp	9 Aug 2004 22:21:54 -0000	1.4
+++ mi2-file.exp	14 Aug 2004 09:38:08 -0000
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 #
 # Test essential Machine interface (MI) operations
 #
@@ -54,8 +51,19 @@
     set srcfilepath [string_to_regexp ${srcdir}/${subdir}/${srcfile}]
 
     # get the path and absolute path to the current executable
+    #
+    # In gdb 6.2 (at least), the default line number is set by
+    # select_source_symtab to the first line of "main" minus
+    # the value of "lines_to_list" (which defaults to 10) plus one.
+    # --chastain 2004-08-13
+
+    set line_main_head [gdb_get_line_number "main ("]
+    set line_main_body [expr $line_main_head + 2]
+    set gdb_lines_to_list 10
+    set line_default [expr $line_main_body - $gdb_lines_to_list + 1]
+
     mi_gdb_test "111-file-list-exec-source-file" \
-	    "111\\\^done,line=\"23\",file=\"${srcfilepath}\",fullname=\"/.*/${srcfile}\"" \
+	    "111\\\^done,line=\"$line_default\",file=\"${srcfilepath}\",fullname=\"/.*/${srcfile}\"" \
                "request path info of current source file (${srcfile})"
 }
 
Index: mi2-return.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi2-return.exp,v
retrieving revision 1.2
diff -u -r1.2 mi2-return.exp
--- mi2-return.exp	9 Aug 2004 22:21:54 -0000	1.2
+++ mi2-return.exp	14 Aug 2004 09:38:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
+# Copyright 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 # Test Machine interface (MI) operations 
 # Verify that, using the MI, we can run a simple program and perform
 # exec-return.  
@@ -51,9 +48,12 @@
     global mi_gdb_prompt
     global hex
 
+    set line_callee3_head         [gdb_get_line_number "callee3 ("]
+    set line_callee3_close_brace  [expr $line_callee3_head + 3]
+
     send_gdb "111-exec-return\n"
     gdb_expect {
-	-re "111\\^done,frame=\{level=\"0\",addr=\"$hex\",func=\"callee3\",args=\\\[.*\\\],file=\".*basics.c\",line=\"18\"\}\r\n$mi_gdb_prompt$" {pass "return from callee4 now"}
+	-re "111\\^done,frame=\{level=\"0\",addr=\"$hex\",func=\"callee3\",args=\\\[.*\\\],file=\".*basics.c\",line=\"$line_callee3_close_brace\"\}\r\n$mi_gdb_prompt$" {pass "return from callee4 now"}
 	-re ".*\r\n$mi_gdb_prompt$" { fail "return from callee4 now" }
 	timeout { fail "return from callee4 now (timeout)"
 	}
Index: mi2-simplerun.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi2-simplerun.exp,v
retrieving revision 1.2
diff -u -r1.2 mi2-simplerun.exp
--- mi2-simplerun.exp	9 Aug 2004 22:21:54 -0000	1.2
+++ mi2-simplerun.exp	14 Aug 2004 09:38:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
+# Copyright 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 #
 # Test essential Machine interface (MI) operations
 #
@@ -53,6 +50,13 @@
     global srcfile
     global hex
 
+    set line_callee4_head  [gdb_get_line_number "callee4 ("]
+    set line_callee3_head  [gdb_get_line_number "callee3 ("]
+    set line_callee2_head  [gdb_get_line_number "callee2 ("]
+    set line_callee2_body  [expr $line_callee2_head + 2]
+    set line_main_head     [gdb_get_line_number "main ("]
+    set line_main_body     [expr $line_main_head + 2]
+
     # Insert some breakpoints and list them
     # Also, disable some so they do not interfere with other tests
     # Tests:
@@ -62,23 +66,23 @@
     # -break-info
 
     mi_gdb_test "200-break-insert main" \
-             "200\\^done,bkpt=\{number=\"1\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"32\",times=\"0\"\}" \
+             "200\\^done,bkpt=\{number=\"1\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"$line_main_body\",times=\"0\"\}" \
              "break-insert operation"
 
     mi_gdb_test "201-break-insert basics.c:callee2" \
-             "201\\^done,bkpt=\{number=\"2\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee2\",file=\".*basics.c\",line=\"22\",times=\"0\"\}" \
+             "201\\^done,bkpt=\{number=\"2\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee2\",file=\".*basics.c\",line=\"$line_callee2_body\",times=\"0\"\}" \
              "insert breakpoint at basics.c:callee2"
 
-    mi_gdb_test "202-break-insert basics.c:15" \
-             "202\\^done,bkpt=\{number=\"3\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee3\",file=\".*basics.c\",line=\"15\",times=\"0\"\}" \
-             "insert breakpoint at basics.c:15 (callee3)"
-
-    mi_gdb_test "203-break-insert \"\\\"${srcfile}\\\":6\"" \
-             "203\\^done,bkpt=\{number=\"4\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"6\",times=\"0\"\}" \
-             "insert breakpoint at \"<fullfilename>\":6 (callee4)"
+    mi_gdb_test "202-break-insert basics.c:$line_callee3_head" \
+             "202\\^done,bkpt=\{number=\"3\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee3\",file=\".*basics.c\",line=\"$line_callee3_head\",times=\"0\"\}" \
+             "insert breakpoint at basics.c:\$line_callee3_head"
+
+    mi_gdb_test "203-break-insert \"\\\"${srcfile}\\\":$line_callee4_head\"" \
+             "203\\^done,bkpt=\{number=\"4\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"$line_callee4_head\",times=\"0\"\}" \
+             "insert breakpoint at \"<fullfilename>\":\$line_callee4_head"
 
     mi_gdb_test "204-break-list" \
-	    "204\\^done,BreakpointTable=\{.*,hdr=\\\[.*\\\],body=\\\[bkpt=\{number=\"1\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"32\",times=\"0\"\},.*\}\\\]\}" \
+	    "204\\^done,BreakpointTable=\{.*,hdr=\\\[.*\\\],body=\\\[bkpt=\{number=\"1\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"$line_main_body\",times=\"0\"\},.*\}\\\]\}" \
                 "list of breakpoints"
 
     mi_gdb_test "205-break-disable 2 3 4" \
@@ -94,6 +98,9 @@
     global mi_gdb_prompt
     global hex
 
+    set line_main_head     [gdb_get_line_number "main ("]
+    set line_main_body     [expr $line_main_head + 2]
+
     # Run the program without args, then specify srgs and rerun the program
     # Tests:
     # -exec-run
@@ -104,7 +111,7 @@
     # The following is equivalent to a send_gdb "000-exec-run\n"
     mi_run_cmd
     gdb_expect {
-	-re "000\\*stopped,reason=\"breakpoint-hit\",bkptno=\"1\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"32\"\}\r\n$mi_gdb_prompt$" {
+	-re "000\\*stopped,reason=\"breakpoint-hit\",bkptno=\"1\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"$line_main_body\"\}\r\n$mi_gdb_prompt$" {
 	    pass "run to main"
 	}
 	-re ".*$mi_gdb_prompt$" {
@@ -120,6 +127,15 @@
     global mi_gdb_prompt
     global hex
 
+    set line_callee4_head         [gdb_get_line_number "callee4 ("]
+    set line_callee4_body         [expr $line_callee4_head + 2]
+    set line_callee3_head         [gdb_get_line_number "callee3 ("]
+    set line_callee3_close_brace  [expr $line_callee3_head + 3]
+    set line_callee1_head         [gdb_get_line_number "callee1 ("]
+    set line_callee1_body         [expr $line_callee1_head + 2]
+    set line_main_head            [gdb_get_line_number "main ("]
+    set line_main_body            [expr $line_main_head + 2]
+
     # Continue execution until a breakpoint is reached, step into calls, verifying
     # if the arguments are correctly shown, continue to the end of a called
     # function, step over a call (next).
@@ -129,24 +145,24 @@
     # -exec-step
     # -exec-finish
 
-    mi_next_to "main" "" "basics.c" "33" "next at main"
+    mi_next_to "main" "" "basics.c" [expr $line_main_body + 1] "next at main"
 
     # FIXME: A string argument is not printed right; should be fixed and
     #        we should look for the right thing here.
     # NOTE: The ``\\\\\"'' is for \".
     mi_step_to "callee1" \
 	"\{name=\"intarg\",value=\"2\"\},\{name=\"strarg\",value=\"$hex \\\\\"A string argument\.\\\\\"\"\},\{name=\"fltarg\",value=\"3.5\"\}" \
-	"basics.c" "27" "step at main"
+	"basics.c" "$line_callee1_body" "step at main"
 
     # FIXME: A string argument is not printed right; should be fixed and
     #        we should look for the right thing here.
     mi_execute_to "exec-step 3" "end-stepping-range" "callee4" "" \
-	"basics.c" "8" "" "step to callee4"
+	"basics.c" $line_callee4_body "" "step to callee4"
 
     # FIXME: A string argument is not printed right; should be fixed and
     #        we should look for the right thing here.
     # NOTE: The ``.'' is part of ``gdb-result-var="$1"''
-    mi_finish_to "callee3" ".*" "basics.c" "18" ".1" "0" "exec-finish"
+    mi_finish_to "callee3" ".*" "basics.c" $line_callee3_close_brace ".1" "0" "exec-finish"
 }
 
 proc test_controlling_breakpoints {} {
Index: mi2-stack.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi2-stack.exp,v
retrieving revision 1.2
diff -u -r1.2 mi2-stack.exp
--- mi2-stack.exp	9 Aug 2004 22:21:54 -0000	1.2
+++ mi2-stack.exp	14 Aug 2004 09:38:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
+# Copyright 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 #
 # Test essential Machine interface (MI) operations
 #
@@ -50,6 +47,9 @@
     global mi_gdb_prompt
     global hex
 
+    set line_callee4_head [gdb_get_line_number "callee4 ("]
+    set line_callee4_body [expr $line_callee4_head + 2]
+
     # Obtain a stack trace
     # Tests:
     # -stack-list-frames
@@ -57,7 +57,7 @@
     # -stack-list-frames 1 3
 
     mi_gdb_test "231-stack-list-frames" \
-	    "231\\^done,stack=\\\[frame=\{level=\"0\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"8\"\},frame=\{level=\"1\",addr=\"$hex\",func=\"callee3\",.*\},frame=\{level=\"2\",addr=\"$hex\",func=\"callee2\",.*\},frame=\{level=\"3\",addr=\"$hex\",func=\"callee1\",.*\},frame=\{level=\"4\",addr=\"$hex\",func=\"main\",.*\}\\\]" \
+	    "231\\^done,stack=\\\[frame=\{level=\"0\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"$line_callee4_body\"\},frame=\{level=\"1\",addr=\"$hex\",func=\"callee3\",.*\},frame=\{level=\"2\",addr=\"$hex\",func=\"callee2\",.*\},frame=\{level=\"3\",addr=\"$hex\",func=\"callee1\",.*\},frame=\{level=\"4\",addr=\"$hex\",func=\"main\",.*\}\\\]" \
                 "stack frame listing"
     mi_gdb_test "232-stack-list-frames 1 1" \
 	    "232\\^done,stack=\\\[frame=\{level=\"1\",addr=\"$hex\",func=\"callee3\",.*\}\\\]" \
@@ -155,10 +155,12 @@
 	    "232\\^done,locals=\\\[name=\"A\",name=\"B\",name=\"C\"\\\]" \
                 "stack locals listing 0"
 
+set line_callee4_return_0 [gdb_get_line_number "return 0;"]
+
 # step until A, B, C, have some reasonable values.
 send_gdb "-exec-next 3\n"
 gdb_expect {
-    -re "\\^running\r\n${mi_gdb_prompt}\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"callee4\",args=\\\[\\\],file=\".*basics.c\",line=\"13\"\}\r\n$mi_gdb_prompt$" {
+    -re "\\^running\r\n${mi_gdb_prompt}\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"callee4\",args=\\\[\\\],file=\".*basics.c\",line=\"$line_callee4_return_0\"\}\r\n$mi_gdb_prompt$" {
 	pass "next's in callee4"
     }
     timeout { fail "next in callee4 (timeout)" }
Index: mi2-stepi.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi2-stepi.exp,v
retrieving revision 1.2
diff -u -r1.2 mi2-stepi.exp
--- mi2-stepi.exp	9 Aug 2004 22:21:54 -0000	1.2
+++ mi2-stepi.exp	14 Aug 2004 09:38:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
+# Copyright 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 # Test Machine interface (MI) operations 
 # Verify that, using the MI, we can run a simple program and perform
 # exec-step-instruction and exec-next-instruction.  
@@ -50,10 +47,19 @@
     global mi_gdb_prompt
     global hex
 
+    set line_main_head  [gdb_get_line_number "main ("]
+    set line_main_body  [expr $line_main_head + 2]
+    set line_main_hello [gdb_get_line_number "Hello, World!"]
+
     send_gdb "111-exec-step-instruction\n"
     gdb_expect {
-	-re "111\\^running\r\n${mi_gdb_prompt}111\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"3.\"\}\r\n$mi_gdb_prompt$" {
-	    pass "step-instruction at main"
+	-re "111\\^running\r\n${mi_gdb_prompt}111\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"(\[0-9\]+)\"\}\r\n$mi_gdb_prompt$" {
+	    set line $expect_out(1,string)
+	    if { $line >= $line_main_body && $line <= $line_main_hello } {
+		pass "step-instruction at main"
+	    } else {
+		fail "step-instruction at main"
+	    }
 	}
 	timeout {
 	    fail "step-instruction at main (timeout)"
@@ -61,8 +67,13 @@
     }
     send_gdb "222-exec-next-instruction\n"
     gdb_expect {
-	-re "222\\^running\r\n${mi_gdb_prompt}222\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"3.\"\}\r\n$mi_gdb_prompt$" {
-	    pass "next-instruction at main"
+	-re "222\\^running\r\n${mi_gdb_prompt}222\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"(\[0-9\]+)\"\}\r\n$mi_gdb_prompt$" {
+	    set line $expect_out(1,string)
+	    if { $line >= $line_main_body && $line <= $line_main_hello } {
+		pass "next-instruction at main"
+	    } else {
+		fail "next-instruction at main"
+	    }
 	}
 	timeout {
 	    fail "next-instruction at main (timeout)"
@@ -70,8 +81,13 @@
     }
     send_gdb "333-exec-next-instruction\n"
     gdb_expect {
-	-re "333\\^running\r\n${mi_gdb_prompt}333\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"3.\"\}\r\n$mi_gdb_prompt$" {
-	    pass "next-instruction at main"
+	-re "333\\^running\r\n${mi_gdb_prompt}333\\*stopped,reason=\"end-stepping-range\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"main\",args=\\\[\\\],file=\".*basics.c\",line=\"(\[0-9\]+)\"\}\r\n$mi_gdb_prompt$" {
+	    set line $expect_out(1,string)
+	    if { $line >= $line_main_body && $line <= $line_main_hello } {
+		pass "next-instruction at main"
+	    } else {
+		fail "next-instruction at main"
+	    }
 	}
 	timeout {
 	    fail "next-instruction at main (timeout)"
Index: mi2-watch.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi2-watch.exp,v
retrieving revision 1.2
diff -u -r1.2 mi2-watch.exp
--- mi2-watch.exp	9 Aug 2004 22:21:54 -0000	1.2
+++ mi2-watch.exp	14 Aug 2004 09:38:08 -0000
@@ -1,4 +1,4 @@
-# Copyright 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
+# Copyright 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -14,9 +14,6 @@
 # along with this program; if not, write to the Free Software
 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  
 
-# Please email any bugs, comments, and/or additions to this file to:
-# bug-gdb@prep.ai.mit.edu
-
 #
 # Test essential Machine interface (MI) operations
 #
@@ -52,6 +49,9 @@
     global srcfile
     global hex
 
+    set line_callee4_head [gdb_get_line_number "callee4 ("]
+    set line_callee4_body [expr $line_callee4_head + 2]
+
     # Insert a watchpoint and list
     # Tests:
     # -break-watch C
@@ -62,7 +62,7 @@
              "break-watch operation"
 
     mi_gdb_test "222-break-list" \
-	    "222\\\^done,BreakpointTable=\{nr_rows=\".\",nr_cols=\".\",hdr=\\\[\{width=\".*\",alignment=\".*\",col_name=\"number\",colhdr=\"Num\"\}.*colhdr=\"Type\".*colhdr=\"Disp\".*colhdr=\"Enb\".*colhdr=\"Address\".*colhdr=\"What\".*\\\],body=\\\[bkpt=\{number=\"1\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"8\",times=\"1\"\},bkpt=\{number=\"2\",type=\".*watchpoint\",disp=\"keep\",enabled=\"y\",addr=\"\",what=\"C\",times=\"0\"\}\\\]\}" \
+	    "222\\\^done,BreakpointTable=\{nr_rows=\".\",nr_cols=\".\",hdr=\\\[\{width=\".*\",alignment=\".*\",col_name=\"number\",colhdr=\"Num\"\}.*colhdr=\"Type\".*colhdr=\"Disp\".*colhdr=\"Enb\".*colhdr=\"Address\".*colhdr=\"What\".*\\\],body=\\\[bkpt=\{number=\"1\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"$line_callee4_body\",times=\"1\"\},bkpt=\{number=\"2\",type=\".*watchpoint\",disp=\"keep\",enabled=\"y\",addr=\"\",what=\"C\",times=\"0\"\}\\\]\}" \
                 "list of watchpoints"
 
 }
@@ -73,17 +73,20 @@
     global srcfile
     global hex
 
+    set line_main_head [gdb_get_line_number "main ("]
+    set line_main_body [expr $line_main_head + 2]
+
     # Insert an access watchpoint and list it
     # Tests:
     # -break-watch -a A
     # -break-list
 
     mi_gdb_test "333-break-watch -a A" \
-             "333\\^done,bkpt=\{number=\"1\",addr=\"$hex\",file=\".*basics.c\",line=\"32\"\}" \
+             "333\\^done,bkpt=\{number=\"1\",addr=\"$hex\",file=\".*basics.c\",line=\"$line_main_body\"\}" \
              "break-watch -a operation"
 
     mi_gdb_test "444-break-list" \
-	    "444\\^done,BreakpointTable=\{.*,hdr=\\\[.*\\\],body=\\\[bkpt=\{number=\"3\",type=\"watchpoint\",disp=\"del\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"32\",times=\"0\"\},.*\}\\\]\}" \
+	    "444\\^done,BreakpointTable=\{.*,hdr=\\\[.*\\\],body=\\\[bkpt=\{number=\"3\",type=\"watchpoint\",disp=\"del\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"$line_main_body\",times=\"0\"\},.*\}\\\]\}" \
                 "list of watchpoints awatch"
 
     mi_gdb_test "777-break-delete 3" \
@@ -97,17 +100,20 @@
     global srcfile
     global hex
 
+    set line_main_head [gdb_get_line_number "main ("]
+    set line_main_body [expr $line_main_head + 2]
+
     # Insert a read watchpoint and list it.
     # Tests:
     # -break-insert -r B
     # -break-list
 
     mi_gdb_test "200-break-watch -r C" \
-             "200\\^done,bkpt=\{number=\"5\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"32\",times=\"0\"\}" \
+             "200\\^done,bkpt=\{number=\"5\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"callee4\",file=\".*basics.c\",line=\"$line_main_body\",times=\"0\"\}" \
              "break-insert -r operation"
 
     mi_gdb_test "300-break-list" \
-	    "300\\^done,BreakpointTable=\{.*,hdr=\\\[.*\\\],body=\\\[bkpt=\{number=\"5\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"32\",times=\"0\"\},.*\}\\\}\}" \
+	    "300\\^done,BreakpointTable=\{.*,hdr=\\\[.*\\\],body=\\\[bkpt=\{number=\"5\",type=\"breakpoint\",disp=\"keep\",enabled=\"y\",addr=\"$hex\",func=\"main\",file=\".*basics.c\",line=\"$line_main_body\",times=\"0\"\},.*\}\\\}\}" \
                 "list of breakpoints"
 
     mi_gdb_test "177-break-delete 4" \
@@ -119,6 +125,10 @@
     global mi_gdb_prompt
     global hex
 
+    set line_callee4_return_0     [gdb_get_line_number "return 0;"]
+    set line_callee3_head         [gdb_get_line_number "callee3 ("]
+    set line_callee3_close_brace  [expr $line_callee3_head + 3]
+
     # Continue execution until the watchpoint is reached,  continue again, 
     # to see the watchpoint go out of scope.
     # Does:
@@ -129,7 +139,7 @@
     gdb_expect {
       -re "222\\^running\r\n$mi_gdb_prompt" {
         gdb_expect {
-	    -re "222\\*stopped,reason=\"watchpoint-trigger\",wpt=\{number=\"2\",exp=\"C\"\},value=\{old=\".*\",new=\"3\"\},thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"callee4\",args=\\\[\\\],file=\".*basics.c\",line=\"13\"\}\r\n$mi_gdb_prompt$" {
+	    -re "222\\*stopped,reason=\"watchpoint-trigger\",wpt=\{number=\"2\",exp=\"C\"\},value=\{old=\".*\",new=\"3\"\},thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"callee4\",args=\\\[\\\],file=\".*basics.c\",line=\"$line_callee4_return_0\"\}\r\n$mi_gdb_prompt$" {
             pass "watchpoint trigger"
           }
           -re ".*$mi_gdb_prompt$" {fail "watchpoint trigger (2)"}
@@ -144,7 +154,7 @@
     gdb_expect {
       -re "223\\^running\r\n$mi_gdb_prompt" {
         gdb_expect {
-	    -re "\[\r\n\]*223\\*stopped,reason=\"watchpoint-scope\",wpnum=\"2\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"callee3\",args=\\\[.*\\\],file=\".*basics.c\",line=\"18\"\}\r\n$mi_gdb_prompt$" {
+	    -re "\[\r\n\]*223\\*stopped,reason=\"watchpoint-scope\",wpnum=\"2\",thread-id=\"\[01\]\",frame=\{addr=\"$hex\",func=\"callee3\",args=\\\[.*\\\],file=\".*basics.c\",line=\"$line_callee3_close_brace\"\}\r\n$mi_gdb_prompt$" {
             pass "wp out of scope"
           }
           -re ".*$mi_gdb_prompt$" {fail "wp out of scope (2)"}



More information about the Gdb-patches mailing list