Module coroutine

Module coroutine 

Source
Expand description

Cooperative coroutines in task.

Structs§

JoinHandle
JoinHandle provides method to retrieve result of associated cooperative task.
Resumption
Resumption provides method to resume suspending coroutine.
Suspension
Suspension provides method to suspend calling coroutine.

Functions§

spawn
Spawns a cooperative task and returns a JoinHandle for it.
suspension
Constructs cooperative facilities to suspend and resume coroutine in current task.
yield_now
Yields coroutine for next scheduling cycle.