From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32698 invoked by alias); 11 Jun 2012 21:22:21 -0000 Received: (qmail 32690 invoked by uid 22791); 11 Jun 2012 21:22:20 -0000 X-SWARE-Spam-Status: No, hits=-5.5 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,KHOP_RCVD_TRUST,KHOP_THREADED,RCVD_IN_DNSWL_LOW,RCVD_IN_HOSTKARMA_YE,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mail-vc0-f169.google.com (HELO mail-vc0-f169.google.com) (209.85.220.169) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 11 Jun 2012 21:22:07 +0000 Received: by vcbfl10 with SMTP id fl10so2993435vcb.0 for ; Mon, 11 Jun 2012 14:22:06 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding:x-system-of-record :x-gm-message-state; bh=ln1fcwWqEiGVbWirAQ7QOD6wCxfHU5sRMkkvTKkI8w8=; b=p4Mg7E02k89nedgy5yf3gi7rPuEbuP3q6x/hAAMmF1eBJEwa1Hjq/EowJjBvGn+gmt lAvrFAnv502q2Kz6L6/5O7/4btoPcwn3GdRscZX2jvJgiHKFGUS8j+FJqnYiwls9ZGKW OZQQG8AyC5w27JYe7wN+SSVX+UuPumQYVn+wqom8lV8eiygIk6IHKTUatT02hnuguPgV DgHShA1i3FszVHS9u8Tu5CVV8uZdG9ArID3Rqf8p7dbIuZPqCDVzSmxr80NKt+VlhaaM aR2zntfqdgTvKok2morT85oF0PD2OBUBOtyikQ2dCQ7TBIN1B7Tpw2IsaXweXO2dox9G VPFg== Received: by 10.220.107.130 with SMTP id b2mr13380814vcp.35.1339449726758; Mon, 11 Jun 2012 14:22:06 -0700 (PDT) MIME-Version: 1.0 Received: by 10.220.107.130 with SMTP id b2mr13380809vcp.35.1339449726627; Mon, 11 Jun 2012 14:22:06 -0700 (PDT) Received: by 10.52.161.199 with HTTP; Mon, 11 Jun 2012 14:22:06 -0700 (PDT) In-Reply-To: References: Date: Mon, 11 Jun 2012 21:22:00 -0000 Message-ID: Subject: Re: [RFC - Python Scripting] Add 'end' attribute to gdb.Symtab_and_line From: Doug Evans To: Siva Chandra Cc: gdb-patches@sourceware.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-System-Of-Record: true X-Gm-Message-State: ALoCoQlgla/qvI8R1eCSXdHGi3yAj+rX3IW/3UrOU7mIlCQh7zgfBol9P8Ha5eaD6XO949cxVizMMB2LHAMJp9uAYrTaW0LiUbvKTwXdTJBclX4w6f79Vf/sh/CtmkoHU7jRl/bA+HHQmKcX+T06SGvz61r29cH5/w== X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2012-06/txt/msg00317.txt.bz2 On Mon, May 21, 2012 at 1:40 AM, Siva Chandra wrot= e: > 2012-05-21 =A0Siva Chandra Reddy =A0 > > =A0 =A0 =A0 =A0New attribute 'end' for gdb.Symtab_and_line. > =A0 =A0 =A0 =A0* NEWS (Python Scripting): Add entry about the new attribu= te. > =A0 =A0 =A0 =A0* python/py-symtab.c (salpy_get_end): New function which > =A0 =A0 =A0 =A0implements the get method for the 'end' attribute of > =A0 =A0 =A0 =A0gdb.Symtab_and_line. > =A0 =A0 =A0 =A0(sal_object_getset): Add entry for the 'end' attribute. > > =A0 =A0 =A0 =A0doc/ > =A0 =A0 =A0 =A0* gdb.texinfo (Symbol Tables In Python): Add description a= bout > =A0 =A0 =A0 =A0the new 'end' attribute of gdb.Symtab_and line. > > =A0 =A0 =A0 =A0testsuite/ > =A0 =A0 =A0 =A0* gdb.python/py-symtab.exp: Add tests to test the new > attribute > =A0 =A0 =A0 =A0'end' of gdb.Symtab_and_line. > =A0 =A0 =A0 =A0* gdb.python/py-symbol.c: Move break point comment to enab= le > =A0 =A0 =A0 =A0testing of gdb.Symtab_and_line.end. > > Thanks, > Siva Chandra Hi. Yeah, "end" would kinda be consistent and is yet a bit too vague. Let's go with "end_pc" and at least leave "pc" alone for now. One question we need to answer is what behaviour to expose in the API. Is the range [pc,end_pc] or [pc,end_pc)? [I know what the internal code does, but we don't have to follow it if it makes for a sufficiently better API.] And we need to clearly document this behaviour. I don't have a strong preference on which one to use. [One recognizes that [pc,end_pc] doesn't have a problem at 0xff...ff, but I'm not sure it matters in practice.]