This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [python] [doc] PR 12930/12802 (clarify Breakpoint::stop doco)
On Thursday 06 October 2011 14:58:27, Phil Muldoon wrote:
> Pedro Alves <pedro@codesourcery.com> writes:
>
> > On Thursday 06 October 2011 11:58:51, Phil Muldoon wrote:
> >>
> >> This patch address the PRs 12930, and 12802 which both arise from
> >> confusion regarding the scope of actions in the Breakpoint::stop
> >> callback. I have added some documentation to clarify.
> >>
> >> Pedro, please excuse the gratuitous CC, but beyond Eli's normal review
> >> can you please fact-check the documentation to make sure I am not
> >> writing something about states that is incorrect.
> >
> > Thanks! Looks good fact-wise. I think infcalls will make sense to call here
> > (we do support them in the normal breakpoint condition), but that
> > supposedly doesn't leave the inferior's state unaltered, so we're good.
> >
> > I could be made possible to self delete a breakpoint in the callback,
> > but that's not the current state of affairs, it seems.
>
> I'm not opposed to allowing the user to delete, but my view is that
> "stop" should make decisions, and not alter state. OTOH, I'm not
> strongly moved other than personal preferences, so I can remove that
> line if need be.
Oh I didn't mean for you to remove it. We can't do that currently,
so let's leave it in. I was thinking that we do have internal
breakpoints that self-delete on some occasions, and it may be
useful to do the same from python --- e.g., local watchpoints going
out of scope, and the scope breakpoint.
--
Pedro Alves