|
From: | Ricardo Gabriel Herdt |
Subject: | Re: [Chicken-users] continuation example: different behavior from other Scheme implementations |
Date: | Sat, 19 Oct 2019 19:36:13 +0200 |
User-agent: | Posteo Webmail |
Am 19.10.2019 18:57 schrieb address@hidden:
But what I forgot, and which may be the confusing part is that after the mapping is complete, "numbers" (in your example) will be assigned once again - the continuation includes everything following the invocation of "map". Only the REPL "cuts off" this continuation (otherwise you would have an infinite loop, similar to when you would run your example code as a non-interactive program).
Thanks again, this makes sense, I had already experienced this infinite loop when using a compiled version of the program.
I added a note to the wiki mentioned (https://en.wikibooks.org/wiki/Scheme_Programming/Continuations) telling to be aware of implementation-dependent behavior, just in case someone stumbles on this issue in the future.
Cheers, Ricardo
[Prev in Thread] | Current Thread | [Next in Thread] |