From: Andrew Cagney <ac131313@cygnus.com>
To: Don Howard <dhoward@redhat.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [RFA] error-catching mechanism for scripts
Date: Wed, 19 Dec 2001 02:36:00 -0000 [thread overview]
Message-ID: <3C206DC1.2030009@cygnus.com> (raw)
In-Reply-To: <Pine.LNX.4.33.0112171700200.18540-100000@theotherone.redhat-remotie.org>
> try
> some commands that might error
> except
> some commands to recover from error
> (errors in this block will not be caught)
> end
Just a question. Given:
try
try
some commands that might error
except
some commands to recover from error
(erros in this block will not be caught)
end
end
I assume the outer try catches errors from the inner except. Looking at
the code, I think this is what happens and, I think, is correct.
What about CNTRL-C? Does that abort the commands or does except catch it?
Hmm (thinking out loud). What about internal-error, er, that throws an
``error'' which the user can now catch. I guess for the moment this is
a feature :-)
BTW, catch_errors() is discouraged in favour of catch_exceptions(). PTR
-> void *.
I see the tests are comming. Ya!
Can I suggest expanding the doco to include an example. Even if it is
just the example you posted with ``some commands that might error'' etc.
I can't think of something that is guarenteed to cause a error - ah, a
`maint error'' command :-/
Andrew
next prev parent reply other threads:[~2001-12-19 10:36 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <Pine.LNX.4.33.0111270827180.2426-100000@theotherone.redhat-remotie.org>
2001-12-18 15:48 ` Don Howard
2001-12-19 2:36 ` Andrew Cagney [this message]
2001-12-19 10:10 ` Eli Zaretskii
2002-01-21 12:28 ` Fernando Nasser
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=3C206DC1.2030009@cygnus.com \
--to=ac131313@cygnus.com \
--cc=dhoward@redhat.com \
--cc=gdb-patches@sources.redhat.com \
/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