This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFC - Python Scripting] New method gdb.Architecture.disassemble
> Date: Mon, 18 Feb 2013 21:36:00 -0800
> From: Siva Chandra <sivachandra@google.com>
> Cc: gdb-patches@sourceware.org, dje@google.com, tromey@redhat.com
>
> On Sat, Feb 16, 2013 at 12:47 AM, Eli Zaretskii <eliz@gnu.org> wrote:
> >> +@defun Architecture.disassemble (@var{start_pc} @r{[}, @var{end_pc} @r{[}, @var{count}@r{]]})
> >> +Return a list of at most @var{count} disassembled instructions
> >> +whose start address falls in the closed memory address interval from
> >> +@var{start_pc} to @var{end_pc}. If @var{end_pc} is not specified, but
> >> +@var{count} is specified, then @var{count} number of instructions
> >> +starting from the address @var{start_pc} are returned. If @var{count}
> >> +is not specified but @var{end_pc} is specified, then all instructions
> >> +whose start address falls in the closed memory address interval from
> >> +@var{start_pc} to @var{end_pc} are returned. If neither @var{end_pc}
> >> +nor @var{count} are specified, then a single instruction at
> >> +@var{start_pc} is returned.
> >
> > The description of the optional arguments makes sense, but the @defun
> > line is in contradiction with the description, because it says that
> > one can specify all 3 arguments. IOW, there should be a '|' somewhere
> > to signal that either end_pc or count, but not both, could be used.
> >
>
> One can specify all three arguments. Does the description anywhere
> indicate otherwise?
The text does not describe that possibility at all, so I assumed that
it cannot happen.