News for hackers. Stuff that matters.
Re:Philosophy of Coroutines by OskarS on Saturday September 02, 2023 @07:30AM (#37360521)
Stackless coroutines are arguably pretty serializable, since they are (usually) implemented by bundling all the relevant data into a struct. There’s no a priori reason that couldn’t be serialized, thiugh I admit I cannot think of an example I’ve seen it used.
Re:Philosophy of Coroutines by clavigne on Saturday September 02, 2023 @11:17AM (#37362272)
We use it at work to send FSMs over the network for distributing tasks. Admittedly we always do this with continuations that haven't started yet, but there is no technical reason we couldn't serialize the already started ones (although you'd have to make sure you also send the coroutines you are currently awaiting on.)