![]() |
awaitable — Convenience alias for asio::awaitable on any_io_executor.
// In header: <boost/taar/core/awaitable.hpp> template<typename T> using awaitable = boost::asio::awaitable< T, boost::asio::any_io_executor >;
Every Taar coroutine runs on an any_io_executor, so it can be spawned on a plain io_context executor or on a strand of one (which is how the servers run each connection when the io_context is driven by several threads). Returning taar::awaitable<T> from a coroutine spares the user from spelling out the executor.