|
|
constexpr | expected (const expected &rhs)=default |
| |
|
constexpr | expected (expected &&rhs)=default |
| |
|
template<class U , class G , std::enable_if_t<!std::is_same_v< expected< U, G >, expected > > * = nullptr, std::enable_if_t< std::is_convertible_v< const G &, E > > * = nullptr, expected_detail::enable_from_other_void_expected_t< E, U, G, const G & > * = nullptr> |
| constexpr | expected (const expected< U, G > &rhs) noexcept(std::is_nothrow_constructible_v< E, const G & >) |
| |
|
template<class U , class G , std::enable_if_t<!std::is_same_v< expected< U, G >, expected > > * = nullptr, std::enable_if_t<!std::is_convertible_v< const G &, E > > * = nullptr, expected_detail::enable_from_other_void_expected_t< E, U, G, const G & > * = nullptr> |
| constexpr | expected (const expected< U, G > &rhs) noexcept(std::is_nothrow_constructible_v< E, const G & >) |
| |
|
template<class U , class G , std::enable_if_t<!std::is_same_v< expected< U, G >, expected > > * = nullptr, std::enable_if_t< std::is_convertible_v< G, E > > * = nullptr, expected_detail::enable_from_other_void_expected_t< E, U, G, G > * = nullptr> |
| constexpr | expected (expected< U, G > &&rhs) noexcept(std::is_nothrow_constructible_v< E, G >) |
| |
|
template<class U , class G , std::enable_if_t<!std::is_same_v< expected< U, G >, expected > > * = nullptr, std::enable_if_t<!std::is_convertible_v< G, E > > * = nullptr, expected_detail::enable_from_other_void_expected_t< E, U, G, G > * = nullptr> |
| constexpr | expected (expected< U, G > &&rhs) noexcept(std::is_nothrow_constructible_v< E, G >) |
| |
|
template<class G , std::enable_if_t<!std::is_convertible_v< const G &, E > > * = nullptr, std::enable_if_t< std::is_constructible_v< E, const G & > > * = nullptr> |
| constexpr | expected (const unexpected< G > &e) noexcept(std::is_nothrow_constructible_v< E, const G & >) |
| |
|
template<class G , std::enable_if_t< std::is_convertible_v< const G &, E > > * = nullptr, std::enable_if_t< std::is_constructible_v< E, const G & > > * = nullptr> |
| constexpr | expected (unexpected< G > const &e) noexcept(std::is_nothrow_constructible_v< E, const G & >) |
| |
|
template<class G , std::enable_if_t<!std::is_convertible_v< G, E > > * = nullptr, std::enable_if_t< std::is_constructible_v< E, G > > * = nullptr> |
| constexpr | expected (unexpected< G > &&e) noexcept(std::is_nothrow_constructible_v< E, G >) |
| |
|
template<class G , std::enable_if_t< std::is_convertible_v< G, E > > * = nullptr, std::enable_if_t< std::is_constructible_v< E, G > > * = nullptr> |
| constexpr | expected (unexpected< G > &&e) noexcept(std::is_nothrow_constructible_v< E, G >) |
| |
|
constexpr | expected (std::in_place_t) noexcept |
| |
|
template<class... Args, std::enable_if_t< std::is_constructible_v< E, Args... > > * = nullptr> |
| constexpr | expected (unexpect_t, Args &&... args) noexcept(std::is_nothrow_constructible_v< E, Args... >) |
| |
|
template<class U , class... Args, std::enable_if_t< std::is_constructible_v< E, std::initializer_list< U > &, Args... > > * = nullptr> |
| constexpr | expected (unexpect_t, std::initializer_list< U > il, Args &&... args) noexcept(std::is_nothrow_constructible_v< E, std::initializer_list< U > &, Args... >) |
| |
|
template<class Fn , class... Args> |
| constexpr | expected (expected_detail::construct_with_invoke_result_t tag1, unexpect_t tag2, Fn &&func, Args &&... args) noexcept(noexcept(static_cast< E >(std::invoke(std::forward< Fn >(func), std::forward< Args >(args)...)))) |
| |
|
expected & | operator= (const expected &rhs)=default |
| |
|
expected & | operator= (expected &&rhs)=default |
| |
|
template<class G , class GF = const G&, std::enable_if_t< std::is_constructible_v< E, GF > &&std::is_assignable_v< E &, GF > > * = nullptr> |
| constexpr expected & | operator= (const unexpected< G > &rhs) noexcept(std::is_nothrow_constructible_v< E, GF > &&std::is_nothrow_assignable_v< E &, GF >) |
| |
|
template<class G , class GF = G, std::enable_if_t< std::is_constructible_v< E, GF > &&std::is_assignable_v< E &, GF > > * = nullptr> |
| constexpr expected & | operator= (unexpected< G > &&rhs) noexcept(std::is_nothrow_constructible_v< E, GF > &&std::is_nothrow_assignable_v< E &, GF >) |
| |
|
constexpr void | emplace () |
| |
|
template<class OE = E> |
| constexpr std::enable_if_t< std::is_swappable_v< OE > &&std::is_move_constructible_v< OE > > | swap (expected &rhs) noexcept(std::is_nothrow_move_constructible_v< E > &&std::is_nothrow_swappable_v< E >) |
| |
|
constexpr void | operator* () const noexcept |
| |
|
constexpr bool | has_value () const noexcept |
| |
|
constexpr | operator bool () const noexcept |
| |
|
constexpr void | value () const & |
| |
|
constexpr void | value () && |
| |
|
constexpr const E & | error () const &noexcept |
| |
|
constexpr E & | error () &noexcept |
| |
|
constexpr const E && | error () const &&noexcept |
| |
|
constexpr E && | error () &&noexcept |
| |
|
template<class G = E> |
| constexpr E | error_or (G &&v) const &noexcept(std::is_nothrow_copy_constructible_v< E > &&expected_detail::is_nothrow_convertible_v< G, E >) |
| |
|
template<class G = E> |
| constexpr E | error_or (G &&v) &&noexcept(std::is_nothrow_move_constructible_v< E > &&expected_detail::is_nothrow_convertible_v< G, E >) |
| |
|
template<class F , class GE = E, std::enable_if_t< std::is_constructible_v< GE, GE & > > * = nullptr> |
| constexpr auto | and_then (F &&f) & |
| |
|
template<class F , class GE = E, std::enable_if_t< std::is_constructible_v< GE, const GE & > > * = nullptr> |
| constexpr auto | and_then (F &&f) const & |
| |
|
template<class F , class GE = E, std::enable_if_t< std::is_constructible_v< GE, GE && > > * = nullptr> |
| constexpr auto | and_then (F &&f) && |
| |
|
template<class F , class GE = E, std::enable_if_t< std::is_constructible_v< GE, const GE > > * = nullptr> |
| constexpr auto | and_then (F &&f) const && |
| |
|
template<class F > |
| constexpr auto | or_else (F &&f) & |
| |
|
template<class F > |
| constexpr auto | or_else (F &&f) const & |
| |
|
template<class F > |
| constexpr auto | or_else (F &&f) && |
| |
|
template<class F > |
| constexpr auto | or_else (F &&f) const && |
| |
|
template<class F , class GE = E, std::enable_if_t< std::is_constructible_v< GE, GE & > > * = nullptr> |
| constexpr auto | transform (F &&f) & |
| |
|
template<class F , class GE = E, std::enable_if_t< std::is_constructible_v< GE, const GE & > > * = nullptr> |
| constexpr auto | transform (F &&f) const & |
| |
|
template<class F , class GE = E, std::enable_if_t< std::is_constructible_v< GE, GE && > > * = nullptr> |
| constexpr auto | transform (F &&f) && |
| |
|
template<class F , class GE = E, std::enable_if_t< std::is_constructible_v< GE, const GE > > * = nullptr> |
| constexpr auto | transform (F &&f) const && |
| |
|
template<class F > |
| constexpr auto | transform_error (F &&f) & |
| |
|
template<class F > |
| constexpr auto | transform_error (F &&f) const & |
| |
|
template<class F > |
| constexpr auto | transform_error (F &&f) && |
| |
|
template<class F > |
| constexpr auto | transform_error (F &&f) const && |
| |