std::execution::just_error

Header: <execution>

A sender factory that returns a sender which completes immediately by calling the receiver’s .

# Declarations

inline constexpr just_error_t just_error{};
struct just_error_t { /*unspecified*/ };

(since C++26) (customization point object)

Call signature
execution::sender auto just_error( auto&& error );

(since C++26)

# Notes

If the provided error is an lvalue reference, a copy is made inside the returned sender and a non-const lvalue reference to the copy is sent to the receiver’s set_error. If the provided value is an rvalue reference, it is moved into the returned sender and an rvalue reference to it is sent to the receiver’s set_error.

# Example

This section is incompleteReason: no example