This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch] [python] find_line_pc_range
On Mon, Jul 4, 2011 at 3:37 AM, Eli Zaretskii <eliz@gnu.org> wrote:
>> Date: Sun, 3 Jul 2011 23:03:51 -0700
>> From: Matt Rice <ratmice@gmail.com>
>> Cc: gdb-patches@sourceware.org
>>
>> Thanks, attached is an updated patch that also includes tests.
>>
>> 2011-07-03 ?Matt Rice ?<ratmice@gmail.com>
>>
>> ? ? ? ? * python/py-symtab.c: Populate sal_object_methods.
>> ? ? ? ? (salpy_find_line_pc_range): New function.
>>
>> 2011-07-03 ?Matt Rice ?<ratmice@gmail.com>
>>
>> ? ? ? ? * gdb.texinfo (Symbol Tables In Python): Add find_line_pc_range method.
>>
>> 2011-07-03 ?Matt Rice ?<ratmice@gmail.com>
>>
>> ? ? ? ? * gdb.python/py-symtab.exp: New Tests for find_line_pc_range.
>
> 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 counter
>> +addresses for the line attribute. ?Otherwise returns @code{None}.
>
> Sorry, I don't understand what you are trying to say here.
> ?"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).
> ?And what "line attribute" do you refer to?
this thing:
— Instance Variable of Symtab_and_line: line
Indicates the current line number for this object. This attribute is
not writable.