Exception-catching adapter for tasks that rely on the default failure mapping.
More...
|
| constexpr | catch_failure_task (Task &&stored_task) noexcept(std::is_nothrow_move_constructible_v< Task >) |
| |
| constexpr | catch_failure_task (const Task &stored_task) noexcept(std::is_nothrow_copy_constructible_v< Task >) |
| |
template<typename Ctx , typename Prev >
requires default_catchable_task<Task, Ctx, Prev> |
| constexpr auto | invoke_raw (exec_context< Ctx, Prev > &ec) noexcept |
| | Executes the wrapped task and maps thrown exceptions to failure.
|
| |
template<typename Ctx , typename Prev , typename U = Task>
requires direct_output_task<U, Ctx, Prev> |
| constexpr step_result | invoke_into (exec_context< Ctx, Prev > &ec, direct_out< detail::declared_task_output_t< U > > out) noexcept |
| |
template<typename Task>
struct yorch::catch_failure_task< Task >
Exception-catching adapter for tasks that rely on the default failure mapping.
The wrapped task itself may throw. This adapter catches any exception, converts it into a compatible failure raw result, and exposes a noexcept invoke_raw(...) protocol to the outer executor.
- Template Parameters
-
Definition at line 19 of file catch_as_failure.hpp.