[rfc/testsuite/mi] use gdb_get_line_number

Michael Chastain mec.gnu@mindspring.com
Wed Aug 11 18:53:00 GMT 2004


Andrew Cagney <cagney@gnu.org> wrote:
ac> Yea, not really. basics.c:callee3 && basics.callee3.prolog?

Okay, I'll take all the line numbers out of the test names, somehow.

mec> # Locate line numbers in basics.c.
mec> set line_callee4        [expr [gdb_get_line_number "callee4 ("]]
mec> set line_callee4_plus_2 [expr [gdb_get_line_number "callee4 ("] + 2]

ac> I'm wondering if the latter should be called:
ac>	line_callee4_past_prologue

Now that you mention it, the "*_plus_2" names look dorky.

Perhaps:

  set line_callee4_head [expr [gdb_get_line_number "callee4 ("]]
  set line_callee4_body [expr [gdb_get_line_number "callee4 ("] + 2]

I like "line_foo_body", but "line_foo_head" sounds a little funny.

Perhaps "line_foo_definition" or "line_foo_defn".

I don't like "line_foo_prologue" because these are lines in the
source file, and the prologue is a property of the object code.

I'll work up another RFC.

Michael C



More information about the Gdb-patches mailing list