unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
From: Chris Vine <vine35792468@gmail.com>
To: guile-user@gnu.org
Subject: Re: "Missing" libraries/concepts found in other languages/ecosystems?
Date: Tue, 14 Jul 2020 17:21:48 +0100	[thread overview]
Message-ID: <20200714172148.38d6e8275d956e7e318dba6c@gmail.com> (raw)
In-Reply-To: <CAJ98PDzmhERmR924_O1hkUhnSHiR3O9i8q19Jfwo++Q7t9cZiw@mail.gmail.com>

On Tue, 14 Jul 2020 12:32:46 +0200
Catonano <catonano@gmail.com> wrote:
> Il giorno dom 12 lug 2020 alle ore 21:33 Chris Vine <vine35792468@gmail.com>
> ha scritto:
> > On Sun, 12 Jul 2020 20:14:23 +0100
> > Chris Vine <vine35792468@gmail.com> wrote:
> > [snip]
> > > Secondly, if the handler returns and #:unwind? is set to #f then
> > > raise-continuable will return with the value returned by the handler.
> > > So this:
> > >
> > >   (with-exception-handler
> > >       (lambda (x) (+ x 3))
> > >     (lambda () (+ (raise-continuable 10) 6)))
> >
> > Ah I see you are using (ice-9 exceptions).  Better be consistent with this:
> >
> >   (with-exception-handler
> >       (lambda (x) (+ x 3))
> >     (lambda () (+ (raise-exception 10 #:continuable? #t) 6))))
> 
> I find this a little bit confusing, admittedly
> 
> so is it
> 
> #:unwind #f
> 
> on with-exception-handler  and
> 
> #:continuable #t
> 
> on raise exception ?

If you want a continuable exception then you don't unwind.  If you
unwind there is no difference between a continuable exception and a
non-continuable one - you have unwound the stack and that's it.

If the exception is non-continuable (as most are), you must either
unwind, or you must in the exception handler re-raise the exception or
invoke your own continuation object.



  parent reply	other threads:[~2020-07-14 16:21 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <mailman.75.1594224014.21222.guile-user@gnu.org>
2020-07-08 18:22 ` "Missing" libraries/concepts found in other languages/ecosystems? Zelphir Kaltstahl
2020-07-09 18:12   ` Leo Butler
2020-07-09 19:34     ` Zelphir Kaltstahl
2020-07-10  7:39   ` Aleix Conchillo Flaqué
2020-07-10  8:14     ` Alex Sassmannshausen
2020-07-10  8:49   ` Catonano
2020-07-10 10:21     ` Chris Vine
2020-07-10 11:20       ` Catonano
2020-07-11  0:19         ` Zelphir Kaltstahl
2020-07-11  0:34           ` Zelphir Kaltstahl
2020-07-11 10:14             ` Chris Vine
2020-07-11 13:45               ` Stefan Israelsson Tampe
2020-07-11 14:46             ` Linus Björnstam
2020-07-11 10:13           ` Chris Vine
2020-07-11 18:20             ` John Cowan
2020-07-11 22:39               ` Chris Vine
2020-07-11 22:41                 ` John Cowan
2020-07-11 23:09                   ` Chris Vine
2020-07-12  1:52                     ` John Cowan
2020-07-12 20:26                       ` Chris Vine
2020-07-13 10:10                 ` Chris Vine
2020-07-12 16:08             ` Catonano
2020-07-12 16:10               ` Catonano
2020-07-12 17:46               ` John Cowan
2020-07-12 19:14               ` Chris Vine
2020-07-12 19:32                 ` Chris Vine
2020-07-14 10:32                   ` Catonano
2020-07-14 11:06                     ` Catonano
2020-07-14 16:21                     ` Chris Vine [this message]
2020-07-12 20:33               ` Zelphir Kaltstahl
2020-07-08  7:38 Simen Endsjø
2020-07-08  8:15 ` Vladimir Zhbanov
2020-07-08 10:08 ` Catonano
2020-07-08 11:29 ` Chris Vine
2020-07-10 12:15 ` Christopher Lam
2020-07-10 15:52   ` Chris Vine

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

  List information: https://www.gnu.org/software/guile/

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

  git send-email \
    --in-reply-to=20200714172148.38d6e8275d956e7e318dba6c@gmail.com \
    --to=vine35792468@gmail.com \
    --cc=guile-user@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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).