Function FiberGroup.spawnFiberIfOpen
Conditionally spawn a new fiber, only if the fiber group is currently open.
This function is useful in certain racy cases, where the fiber group has been closed, but has not yet finished closing.
Parameters
Name | Description |
---|---|
dg | the delegate to run inside the fiber |
Returns
The FiberHandle of the new fiber if successful, the invalid FiberHandle if the fiber group is closed or closing.