dispatchrun / coroutine

Durable coroutines for Go

Home Page:https://dispatch.run

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Local variables are recreated when resuming coroutines

achille-roussel opened this issue · comments

On resumption, the call stack of coroutines is recreated by walking through it from the entry point and to the last yield location. This causes local variables declared in function bodies to be recreated, and obtain new addresses. This causes a situation where in cases where those variables had their address taken and serialized, the deserialization and rewinding process create two copies of those variables.

See #56 for an example of this issue.