mrs_lib
Various reusable classes, functions and utilities for use in MRS projects
Loading...
Searching...
No Matches
mrs_lib::Task< T > Class Template Reference

Task type for creating coroutines. More...

#include <task.hpp>

Public Types

using promise_type = internal::PromiseType<T>

Public Member Functions

 Task (const Task &)=delete
 Task (Task &&)=delete
Task & operator= (const Task &)=delete
Task & operator= (Task &&)=delete

Friends

class internal::PromiseType< T >
internal::TaskAwaitable< T > operator co_await (Task task)

Detailed Description

template<typename T>
requires (std::same_as<T, std::remove_cvref_t<T>>)
class mrs_lib::Task< T >

Task type for creating coroutines.

Template Parameters
TReturn type of the coroutine (default is void)

Task is lazy coroutine, which means it must be co_awaited to start executing.


The documentation for this class was generated from the following file:
  • /home/runner/work/mrs_lib/mrs_lib/include/mrs_lib/coro/task.hpp