Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Gary Benson <gbenson@redhat.com>
To: Ruslan Kabatsayev <b7.10110111@gmail.com>
Cc: psmith@gnu.org, gdb@sourceware.org
Subject: Re: gdb -batch always exits with status 0
Date: Fri, 17 Aug 2018 16:03:00 -0000	[thread overview]
Message-ID: <20180817160325.GA12274@blade.nx> (raw)
In-Reply-To: <CAHEcG96yy8tekiVGjSvjn=AnmFkYRzPhCL_+5tSNj-81-D6HUw@mail.gmail.com>

Ruslan Kabatsayev wrote:
> On Fri, 17 Aug 2018 at 18:23, Gary Benson <gbenson@redhat.com> wrote:
> >
> > It would be the least impactful way, sure, but my point is that
> > GDB doesn't operate in an intuitive way, and my view is that
> > whatever is intuitive should be the default.  Having to request it
> > with a special flag makes GDB harder for new users.
> 
> Not sure about intuitiveness of early exit, but we have an example
> of the converse: bash (and other shells). Namely, by default it
> executes all the commands, exits with the exit status of the last
> command executed. But you can `set -e`, and then first failing
> command will stop processing. But then, there do exist means to
> suppress failure (e.g. `badCommand && true`), which GDB doesn't seem
> to have.

Shells are the only example I could think of.  And I wonder what
proportion of shell scripts start with 'set -e' :)  Having to add
that is the kind of thing I mean about making things harder for
new users.

Cheers,
Gary


  reply	other threads:[~2018-08-17 16:03 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-05 14:47 Gary Benson
2018-07-05 14:55 ` Ruslan Kabatsayev
2018-07-05 15:23 ` Paul Smith
2018-08-17 11:03   ` Gary Benson
2018-08-17 11:25     ` Ruslan Kabatsayev
2018-08-17 13:24     ` Paul Smith
2018-08-17 15:23       ` Gary Benson
2018-08-17 15:44         ` Ruslan Kabatsayev
2018-08-17 16:03           ` Gary Benson [this message]
2018-08-17 18:30             ` Pedro Alves
2018-08-22  9:07               ` Gary Benson

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=20180817160325.GA12274@blade.nx \
    --to=gbenson@redhat.com \
    --cc=b7.10110111@gmail.com \
    --cc=gdb@sourceware.org \
    --cc=psmith@gnu.org \
    /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