|
Uni20
Asynchronous tensor and runtime library.
|
Factory for producing multiple BasicTask ownership claims for one coroutine. More...
#include <async_task_promise.hpp>
Public Member Functions | |
| TaskFactory & | operator= (TaskFactory &&other) noexcept |
| Move assignment. | |
| TaskFactory & | operator= (TaskFactory const &)=delete |
| BasicTask | take_next () |
| Dispense the next BasicTask from the pool of shared ownership handles. | |
| TaskFactory (TaskFactory &&other) noexcept | |
| TaskFactory (TaskFactory const &)=delete | |
| ~TaskFactory () noexcept | |
| Destructor returns any unused ownership claims and may destroy the coroutine. | |
Friends | |
| class | TaskPromiseBase |
Factory for producing multiple BasicTask ownership claims for one coroutine.
This is used when multiple awaiters (e.g., in an all(A, B, C) construct) need to take independent ownership of the same coroutine. The factory pre-allocates all references atomically and ensures that they are handed out exactly once.
|
inlinenoexcept |
|
delete |
|
inlinenoexcept |
Destructor returns any unused ownership claims and may destroy the coroutine.
If any BasicTask values were not handed out via take_next(), they are released here. If the coroutine is unowned after release, it will be destroyed.
|
inlinenoexcept |
Move assignment.
| other | Source factory. |
*this.
|
delete |
|
inline |
|
friend |