Re: [patch] Add an evaluation function hook to Python breakpoints.

Doug Evans
2010-12-28T05:08:40Z

On Wed, Dec 22, 2010 at 8:19 AM, Tom Tromey <tromey@redhat.com> wrote:
>>>>>> "Doug" == Doug Evans <dje@google.com> writes:
>
>>> The method in question is attached to a particular breakpoint.  So, if
>>> it requests a stop, it will be reported as coming from that breakpoint.
>
> Doug> That feels a bit subtle (and easy for the user to confuse with a
> Doug> normal breakpoint).
>
> But it will actually be a normal breakpoint.

Right, that's my point.
The user will see the normal breakpoint output, and then be expected
to know that the breakpoint is special (e.g., a rule was violated and
that s/he needs to pay attention to what the rule was). Is there a
plan to have something more? [Or am I missing something?]

> Doug> Plus will it also breakdown if a developer sets his/her own breakpoint
> Doug> at that location?
>
> No, it will continue to do the right thing.  In fact that is one of the
> major points of this patch, see the requirements upthread.

Sorry, maybe I was too subtle.
If one is using this facility to implement a rule checker that stops
when the rule is violated, and one sets another breakpoint at the same
location, when the program stops how does one know whether the rule
was violated or not?
[Especially if all that is reported is the normal breakpoint output.]