This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] Small fixes to the Python API doc
- From: Phil Muldoon <pmuldoon at redhat dot com>
- To: Simon Marchi <simon dot marchi at ericsson dot com>, gdb-patches at sourceware dot org
- Date: Thu, 16 Oct 2014 19:18:24 +0100
- Subject: Re: [PATCH] Small fixes to the Python API doc
- Authentication-results: sourceware.org; auth=none
- References: <1413482796-3090-1-git-send-email-simon dot marchi at ericsson dot com>
On 16/10/14 19:06, Simon Marchi wrote:
> First:
> "Breakpoint.delete" is missing parenthesis.
>
> Second:
> Someone on IRC asked, how come there is no disable() method in the
> Breakpoint object. It turns out you have to do "bp.enabled = False".
> Since every normal person would probably search for "disable" in that page
> if their intent is to disable a python breakpoint, I thought it would be
> useful if the description contained "disable" so it would be easy to find.
> The result might seem a bit silly and redundant, so I am open to
> suggestions.
>
> gdb/doc/ChangeLog:
>
> * python.texi (Breakpoints In Python): Add parenthesis after
> Breakpoint.delete. Clarify Breakpoint.enabled description so
> that it contains "disable".
> ---
> gdb/doc/python.texi | 5 +++--
> 1 file changed, 3 insertions(+), 2 deletions(-)
>
>
> @defvar Breakpoint.enabled
> This attribute is @code{True} if the breakpoint is enabled, and
> -@code{False} otherwise. This attribute is writable.
> +@code{False} otherwise. You can use it to enable or disable the breakpoint.
> +This attribute is writable.
> @end defvar
>
> @defvar Breakpoint.silent
No objections to the patch, but maybe we should "just have" a
disable() method even if it duplicates the functionality of the
enabled attribute. What do you think?
Cheers
Phil