internal/task: swap stack chain when switching goroutines

This change swaps the stack chain when switching goroutines, ensuring that the chain is maintained consistently.
This is only really currently necessary with asyncify on wasm.
This commit is contained in:
Nia Waldvogel
2021-12-14 16:48:11 -05:00
committed by Ayke
parent d5c0083085
commit e4de7b4957
10 changed files with 51 additions and 4 deletions
+3
View File
@@ -15,6 +15,9 @@ type Task struct {
// Data is a field which can be used for storing state information.
Data uint64
// gcData holds data for the GC.
gcData gcData
// state is the underlying running state of the task.
state state
}