From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12727 invoked by alias); 4 Jul 2011 10:50:28 -0000 Received: (qmail 12717 invoked by uid 22791); 4 Jul 2011 10:50:26 -0000 X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW X-Spam-Check-By: sourceware.org Received: from mail-yx0-f169.google.com (HELO mail-yx0-f169.google.com) (209.85.213.169) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 04 Jul 2011 10:50:12 +0000 Received: by yxn22 with SMTP id 22so1933807yxn.0 for ; Mon, 04 Jul 2011 03:50:11 -0700 (PDT) MIME-Version: 1.0 Received: by 10.236.66.1 with SMTP id g1mr2125302yhd.304.1309776611710; Mon, 04 Jul 2011 03:50:11 -0700 (PDT) Received: by 10.236.95.167 with HTTP; Mon, 4 Jul 2011 03:50:11 -0700 (PDT) In-Reply-To: References: Date: Mon, 04 Jul 2011 10:56:00 -0000 Message-ID: Subject: Re: [patch] [python] find_line_pc_range From: Matt Rice To: Eli Zaretskii Cc: pmuldoon@redhat.com, gdb-patches@sourceware.org Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable 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: 2011-07/txt/msg00088.txt.bz2 On Mon, Jul 4, 2011 at 3:37 AM, Eli Zaretskii wrote: >> Date: Sun, 3 Jul 2011 23:03:51 -0700 >> From: Matt Rice >> Cc: gdb-patches@sourceware.org >> >> Thanks, attached is an updated patch that also includes tests. >> >> 2011-07-03 =A0Matt Rice =A0 >> >> =A0 =A0 =A0 =A0 * python/py-symtab.c: Populate sal_object_methods. >> =A0 =A0 =A0 =A0 (salpy_find_line_pc_range): New function. >> >> 2011-07-03 =A0Matt Rice =A0 >> >> =A0 =A0 =A0 =A0 * gdb.texinfo (Symbol Tables In Python): Add find_line_p= c_range method. >> >> 2011-07-03 =A0Matt Rice =A0 >> >> =A0 =A0 =A0 =A0 * gdb.python/py-symtab.exp: New Tests for find_line_pc_r= ange. > > Thanks. > > Comments about the documentation part: > >> +@defmethod Symtab_and_line find_line_pc_range >> +If found returns a @code{Tuple} containing the start and end program co= unter >> +addresses for the line attribute. =A0Otherwise returns @code{None}. > > Sorry, I don't understand what you are trying to say here. > =A0"If found" > what? Sorry, I abhor writing. find_line_pc_range will not find a range in cases where the code is not associated with a line (no debug symbols), or the line is not associated with code (ifdef'd out or something). > =A0And what "line attribute" do you refer to? this thing: =97 Instance Variable of Symtab_and_line: line Indicates the current line number for this object. This attribute is not writable.