ScopedValue structured forking/forwarding API
Robert Engels
robaho at me.com
Mon Jul 14 11:42:30 UTC 2025
I’ve previously proven you don’t need coroutines to implement generators.
Code is here https://github.com/robaho/generators
As for other worthwhile CPS usages I guess you’d have to show me because I doubt it.
> On Jul 14, 2025, at 5:15 AM, Andrew Haley <aph-open at littlepinkcloud.com> wrote:
>
> On 13/07/2025 21:34, Robert Engels wrote:
>> The whole point of virtual threads is to avoid coroutines / async functions.
>
> I'm not sure that's really true. Continuation-passing style and coroutines have their uses even in the presence of virtual threads, as do things like generators. I don't much like coloured functions (does anyone?) but CPS is more general than vthreads.
>
> --
> Andrew Haley (he/him)
> Java Platform Lead Engineer
> https://keybase.io/andrewhaley
> EAC8 43EB D3EF DB98 CC77 2FAD A5CD 6035 332F A671
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/loom-dev/attachments/20250714/c26b8556/attachment.htm>
More information about the loom-dev
mailing list