#include <fastmm/core/result.hpp>
|
| constexpr | Result (const T &v) noexcept(std::is_nothrow_copy_constructible_v< T >) |
| |
| constexpr | Result (T &&v) noexcept(std::is_nothrow_move_constructible_v< T >) |
| |
| constexpr | Result (Unexpected< E > u) noexcept(std::is_nothrow_move_constructible_v< E >) |
| |
| constexpr | Result (const Result &o) noexcept(std::is_nothrow_copy_constructible_v< T > &&std::is_nothrow_copy_constructible_v< E >) |
| |
| constexpr | Result (Result &&o) noexcept(std::is_nothrow_move_constructible_v< T > &&std::is_nothrow_move_constructible_v< E >) |
| |
| constexpr Result & | operator= (const Result &o) |
| |
| constexpr Result & | operator= (Result &&o) noexcept(std::is_nothrow_move_constructible_v< T > &&std::is_nothrow_move_constructible_v< E >) |
| |
| | ~Result () |
| |
| constexpr bool | has_value () const noexcept |
| |
| constexpr | operator bool () const noexcept |
| |
| constexpr T & | value () &noexcept |
| |
| constexpr const T & | value () const &noexcept |
| |
| constexpr T && | value () &&noexcept |
| |
| constexpr const E & | error () const noexcept |
| |
| constexpr E & | error () noexcept |
| |
| constexpr T & | operator* () noexcept |
| |
| constexpr const T & | operator* () const noexcept |
| |
| constexpr T * | operator-> () noexcept |
| |
| constexpr const T * | operator-> () const noexcept |
| |
| template<class U > |
| constexpr T | value_or (U &&fallback) const |
| |
| template<class F > |
| constexpr auto | and_then (F &&f) const -> std::invoke_result_t< F, const T & > |
| | Monadic chaining: f(T) must return Result<U, E>.
|
| |
| template<class F > |
| constexpr auto | map (F &&f) const -> Result< std::invoke_result_t< F, const T & >, E > |
| | map: f(T) returns U, yields Result<U, E>.
|
| |
◆ value_type
template<class T , class E >
◆ error_type
template<class T , class E >
◆ Result() [1/5]
template<class T , class E >
◆ Result() [2/5]
template<class T , class E >
◆ Result() [3/5]
template<class T , class E >
◆ Result() [4/5]
template<class T , class E >
◆ Result() [5/5]
template<class T , class E >
◆ ~Result()
template<class T , class E >
◆ operator=() [1/2]
template<class T , class E >
◆ operator=() [2/2]
template<class T , class E >
◆ has_value()
template<class T , class E >
◆ operator bool()
template<class T , class E >
|
|
inlineexplicitconstexprnoexcept |
◆ value() [1/3]
template<class T , class E >
◆ value() [2/3]
template<class T , class E >
◆ value() [3/3]
template<class T , class E >
◆ error() [1/2]
template<class T , class E >
◆ error() [2/2]
template<class T , class E >
◆ operator*() [1/2]
template<class T , class E >
◆ operator*() [2/2]
template<class T , class E >
◆ operator->() [1/2]
template<class T , class E >
◆ operator->() [2/2]
template<class T , class E >
◆ value_or()
template<class T , class E >
template<class U >
◆ and_then()
template<class T , class E >
template<class F >
| constexpr auto fastmm::Result< T, E >::and_then |
( |
F && |
f | ) |
const -> std::invoke_result_t<F, const T&> |
|
inlineconstexpr |
Monadic chaining: f(T) must return Result<U, E>.
◆ map()
template<class T , class E >
template<class F >
| constexpr auto fastmm::Result< T, E >::map |
( |
F && |
f | ) |
const -> Result<std::invoke_result_t<F, const T&>, E> |
|
inlineconstexpr |
map: f(T) returns U, yields Result<U, E>.
◆ value_
template<class T , class E >
◆ error_
template<class T , class E >