|
| template<typename... ArgTypes, constraints< std::enable_if_t< all_of_v<!std::is_same< remove_cvref_t< ArgTypes >, error_result_t >::value... > > > = nullptr> |
| constexpr | error_result_t (ArgTypes &&... args) noexcept(std::is_nothrow_constructible< ErrorType, ArgTypes... >::value) |
| | Construct the stored error from the specified arguments.
|
| |
| constexpr | error_result_t (error_result_t &&)=default |
| | Move constructor.
|
| |
| constexpr | error_result_t (error_result_t const &)=default |
| | Copy constructor.
|
| |
| | ~error_result_t ()=default |
| | destructor
|
| |
| template<typename Value> |
| constexpr | operator result< Value, ErrorType > () &&noexcept(noexcept(result< Value, ErrorType >(in_place_error, std::declval< ErrorType && >()))) |
| | Instantiates a result<Value,ErrorType> from the contained error instance, moving the error value into the result.
|
| |
| template<typename Value> |
| constexpr | operator result< Value, ErrorType > () const &noexcept(noexcept(result< Value, ErrorType >(in_place_error, std::declval< ErrorType const & >()))) |
| | Instantiates a result<Value,ErrorType> from the contained error instance.
|
| |
| constexpr auto | operator= (error_result_t &&) -> error_result_t &=default |
| | Move constructor.
|
| |
| constexpr auto | operator= (error_result_t const &) -> error_result_t &=default |
| | Copy assignment.
|
| |
template<typename ErrorType>
class arene::base::error_result_t< ErrorType >
Intermediary type for constructing a result with a given error_type .
- Note
- Generally this should not be constructed manually; it intended as a transient type that allow to construct a
result Object while using type deduction for value_type and error_type .
- Template Parameters
-
| ErrorType | the error_type of a result constructed from this type. |
- See also
arene::base::error_result for the factory function that should be used in user code.