Currently the Sink only returns the carried value once the scope and all tasks have finished. This limits the use cases.
A new method on Sink should be added, along with a new method on Continuation, to return a Generator where the scope has the possibility to yield values on each run.
This opens the possibility to build asynchronous systems that stream data.
Maybe it should be explored a way for tasks to stream data as well.
Currently the
Sinkonly returns the carried value once the scope and all tasks have finished. This limits the use cases.A new method on
Sinkshould be added, along with a new method onContinuation, to return aGeneratorwhere the scope has the possibility to yield values on each run.This opens the possibility to build asynchronous systems that stream data.
Maybe it should be explored a way for tasks to stream data as well.