Racket version 7.1 is now available from
http://racket-lang.org/
* Although it is still not part of this release, the development of
Racket on Chez Scheme continues. We still hope and expect that
Racket-on-Chez will be ready for production use later in the v7.x
series, perhaps mid-2019.
Because applying the continuation captured by Racket's
call-with-current-continuation will *replace* existing continuations.
Therefore the exception handler is removed. To obtain a continuation
that will only *extend* the current continuation, use
call-with-composable-continuation.
(Another way to
Thanks Shu-hung.
So here is my understanding:
#lang racket
(begin
(define saved-k #f) ; wrapped in "prompt 1"
(+ 1 (call/cc
(lambda (k)
(set! saved-k k)
0))) ; wrapped in "prompt 2"
(println 'hello) ; wrapped in "prompt 3"
(saved-k 100) ; wrapped in "prom
3 matches
Mail list logo