-
Notifications
You must be signed in to change notification settings - Fork 14
Description
This Stack Switching Proposal introduces one-shot continuations, which are efficient and align with a contiguous stack model. However, languages like Scheme, Racket, and other functional or dynamic languages rely on multi-shot continuations (e.g., call/cc), which can be invoked multiple times and require capturing and restoring the stack.
Would it be feasible to optionally support multi-shot continuations in this proposal? This could allow languages that depend on full continuation support to target WebAssembly without losing core features. Even if there’s a performance trade-off (e.g., using a linked-list stack or stack copying), having the option would broaden WebAssembly’s applicability.
Note : Racket supports both one shot and reusable continuations, both delimited. Scheme only supports undelinited reusable continuations, but they can be implemented over delimited ones