Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Doug Evans <dje@google.com>
To: Stan Shebs <stanshebs@earthlink.net>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH] Make enable reset disposition
Date: Fri, 27 Jan 2012 01:47:00 -0000	[thread overview]
Message-ID: <CADPb22Qbi1=sH9CB-2UjsM19soB=6V-k4kOvdE0xgWFJvm0b=A@mail.gmail.com> (raw)
In-Reply-To: <4F21EE80.104@earthlink.net>

On Thu, Jan 26, 2012 at 4:23 PM, Stan Shebs <stanshebs@earthlink.net> wrote:
> In the process of developing an additional enablement option (to be posted
> soon), I ran across this little bit of behavior that seems wrong; if you do
> "enable once" and then "enable" on a breakpoint, the disposition is
> unchanged - the breakpoint is still going to get disabled after being hit.
>  (Similarly for "enable delete" breakpoints.)
>
> While one could argue that this is good, because you can toggle a
> breakpoint's enablement independently of its ultimate disposition, the
> downside is that you're stuck with your original choice; once you've set a
> breakpoint's disposition to delete for instance, there is no way to undo
> that, and when the breakpoint is hit, it's gone, conditions and command list
> and all.
>
> Having "enable" reset dispositions has its own fault, namely that if you do
> just "enable" to enable all breakpoints, and they have different
> dispositions, then all the dispositions are reset en masse, and you would
> have to manually do a combination of "enable once", "enable delete", etc to
> get those back to desired values.
>
> A more complicated solution might be to introduce an additional flavor or
> option of enable command ("enable always"?), but I wouldn't like to try to
> explain the different flavors to users, and chances are that nobody would
> remember it anyway.

Hi.
I don't know that I would call it *more* complicated.
IIUC, there two independent(/orthogonal) attributes of a breakpoint
(once vs delete vs always, and enabled vs disabled) and they are
controlled by the same command.
Oops.

From a u/i perspective keeping the orthogonality feels right.
Also, having "enable" reset dispositions en masse does bother me.
Does this affect tbreak-created breakpoints?

It feels like adding "always" doesn't muddy the waters any more than
they already are. :-)
If one were do do this again, having a new command instead of "enable"
may be easier for user's to digest and remember.


  reply	other threads:[~2012-01-27  0:43 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-01-27  0:43 Stan Shebs
2012-01-27  1:47 ` Doug Evans [this message]
2012-02-06 19:50 ` Tom Tromey

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CADPb22Qbi1=sH9CB-2UjsM19soB=6V-k4kOvdE0xgWFJvm0b=A@mail.gmail.com' \
    --to=dje@google.com \
    --cc=gdb-patches@sourceware.org \
    --cc=stanshebs@earthlink.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox