|
Async++ unknown
Async (co_await/co_return) code for C++
|
Utility functions for quickly converting a awaitable to a std::future. More...
#include <asyncpp/fire_and_forget.h>#include <future>Go to the source code of this file.
Functions | |
| template<typename T , typename Awaitable > requires (!std::is_void_v<T>) | |
| std::future< T > | asyncpp::as_promise (Awaitable &&awaiter) |
| Execute the given awaitable and return a std::promise representing the call. | |
| template<typename T , typename Awaitable > requires (std::is_void_v<T>) | |
| std::future< void > | asyncpp::as_promise (Awaitable &&awaiter) |
| Execute the given awaitable and return a std::promise representing the call. | |
| auto | asyncpp::as_promise (auto &&awaiter) |
| Execute the given awaitable and return a std::promise representing the call. | |
Utility functions for quickly converting a awaitable to a std::future.
| auto asyncpp::as_promise | ( | auto && | awaiter | ) |
Execute the given awaitable and return a std::promise representing the call.
This can be used to synchronously wait for the result of a coroutine.
| std::future< T > asyncpp::as_promise | ( | Awaitable && | awaiter | ) |
Execute the given awaitable and return a std::promise representing the call.
This can be used to synchronously wait for the result of a coroutine.
| std::future< void > asyncpp::as_promise | ( | Awaitable && | awaiter | ) |
Execute the given awaitable and return a std::promise representing the call.
This can be used to synchronously wait for the result of a coroutine.