I always start Matt Might articles thinking "Okay, THIS is the one I'm going to understand all the way to the very end without unlearning what I just read, else I die," and alas, I have again died.
(display
(call/cc (lambda (cc)
(display "I got here.\n")
(cc "This string was passed to the continuation.\n")
(display "But not here.\n"))))
Edit: Tried playing around with mit-scheme, but it doesn't work with the ctrl-v'ing the examples. Chezscheme does work.Changing it to the following should work:
(let ((start #f))
(if (not start)
(call/cc (lambda (cc)
(set! start cc))))
(display "Going to invoke (start)\n")
(start #f))
[0] https://www.gnu.org/software/mit-scheme/documentation/stable...Full disclosure: I'm the one who built / owns the first project.