tur/workflow

stdlib/workflow.tur
defn

save-cont!

(save-cont! [k :ptr<void>] :ptr<void>)

serialise an opaque serial-continuation handle to a bytes value.

kopaque continuation pointer from serial-shift

Since: Phase 21

defn

resume-cont!

(resume-cont! [b :ptr<void> v :int] :int)

deserialise a bytes value and resume the encoded continuation with v.

bserialised bytes from save-cont!
vvalue to pass to the resumed continuation

Since: Phase 21

defn

workflow-suspend

(workflow-suspend [k :ptr<void>] :ptr<void>)

suspend the current workflow step by serialising continuation k.

kopaque continuation pointer from serial-shift

Since: Phase 21

defn

workflow-resume

(workflow-resume [b :ptr<void> v :int] :int)

resume a previously suspended workflow step with value v.

bbytes value produced by workflow-suspend
vvalue to inject into the resumed continuation

Since: Phase 21