From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1545 invoked by alias); 11 Aug 2004 18:08:47 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 1537 invoked from network); 11 Aug 2004 18:08:45 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sourceware.org with SMTP; 11 Aug 2004 18:08:45 -0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.12.10/8.12.10) with ESMTP id i7BI8ee3015781 for ; Wed, 11 Aug 2004 14:08:45 -0400 Received: from localhost.redhat.com (porkchop.devel.redhat.com [172.16.58.2]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id i7BI8Ya30712; Wed, 11 Aug 2004 14:08:34 -0400 Received: from gnu.org (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id 5409B2B9D; Wed, 11 Aug 2004 14:08:29 -0400 (EDT) Message-ID: <411A609D.3080306@gnu.org> Date: Wed, 11 Aug 2004 18:08:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-GB; rv:1.4.1) Gecko/20040801 MIME-Version: 1.0 To: Michael Chastain Cc: cagney@redhat.com, ezannoni@redhat.com, gdb-patches@sources.redhat.com Subject: Re: [rfc/testsuite/mi] use gdb_get_line_number References: <41188B2A.nailK7Y1RD9SU@mindspring.com> In-Reply-To: <41188B2A.nailK7Y1RD9SU@mindspring.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2004-08/txt/msg00400.txt.bz2 > Here is a draft patch for gdb.mi/mi-break.exp to use > gdb_get_line_number. > > It works, but that's beside the point. I'm looking for the right style. > So this is RFC, not RFA. > > Some questions: > > . there are a lot of line_* variables. how would you like me to name > them and manage them? > > . some of the test names have line numbers embedded in them: > > "insert temp breakpoint at basics.c:15 (callee3)" > > this is now > > "insert temp breakpoint at basics.c:$line_callee3 (callee3)" > > so the name floats around as basics.c changes. That is, I just > did the simple stupid substitution. What would you really like for > test names like this? Yea, not really. basics.c:callee3 && basics.callee3.prolog? > + # Locate line numbers in basics.c. > + set line_callee4 [expr [gdb_get_line_number "callee4 ("]] > + set line_callee4_plus_2 [expr [gdb_get_line_number "callee4 ("] + 2] I'm wondering if the latter should be called: line_callee4_past_prologue (that specific name is bad but I think the intent is clear) so it's clear that it is past the callee4's prologu. Andrew