TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Continuations by Example

15 pointsby marvinborner11 months ago

2 comments

jacknews11 months ago
I don&#x27;t find the description or the examples here very well explained. What does call&#x2F;cc do? What does cc do? what is this code, or is it just a comment?<p><pre><code> (continuation of 3 \* (f() + 8))(result) ; </code></pre> The descriptions are just hard to parse:<p><pre><code> The value passed to the continuation is the return value of the call. During the execution of the expression body, the variable current-continuation is bound to the current continuation. If invoked, current-continuation immediately returns from the call to call&#x2F;cc ... </code></pre> And the initial &#x27;teaser&#x27; is explained later, but not demonstrated by showing actuial code for assert and amb.
JoelMcCracken11 months ago
I’m not super well versed in continuations, is right-now&#x2F;go-when analogous to reset and shift, or are these different ideas?