Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Supporting continuations #1607

Open
vkuncak opened this issue Dec 5, 2024 · 0 comments
Open

Supporting continuations #1607

vkuncak opened this issue Dec 5, 2024 · 0 comments
Labels

Comments

@vkuncak
Copy link
Collaborator

vkuncak commented Dec 5, 2024

Continuations are often modeled as first-class functions, but they are very special: often nothing ever happens after they are done executing. Hence, a continuation should be of Cont[A] type similar to (A => Nothing). If we can specify preconditions (refinements) on A, then we do not need to worry about the effects of the continuation, so we could allow effects in the body of continuation.

All this speaks in favor of defining Continuation trait with precondition on its apply and more flexible rules for effects.

@vkuncak vkuncak added the feature label Dec 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant