|
| constexpr | Optional ()=default |
| constexpr | Optional (NullOpt) |
| constexpr | Optional (Optional const &)=default |
| constexpr | Optional (Optional &&)=default |
| constexpr auto | operator= (Optional const &) -> Optional &=default |
| constexpr auto | operator= (Optional &&) -> Optional &=default |
| constexpr | ~Optional ()=default |
| constexpr | Optional (Optional const &other) |
| constexpr | Optional (Optional &&other) |
template<typename U>
requires (!concepts::SameAs<T, U> && concepts::ConstructibleFrom<T, U const&> && !ConstructibleFromCRefOptional<T, Optional<U>>) |
| constexpr | explicit (!concepts::ImplicitlyConvertibleTo< U const &, T >) Optional(Optional< U > const &other) |
template<typename U>
requires (!concepts::SameAs<T, U> && concepts::ConstructibleFrom<T, U &&> && !ConstructibleFromCRefOptional<T, Optional<U>>) |
| constexpr | explicit (!detail::OptionalConvertibleToWorkaround< Optional, U &&, T >) Optional(Optional< U > &&other) |
template<typename... Args>
requires (concepts::ConstructibleFrom<T, Args...>) |
| constexpr | Optional (types::InPlace, Args &&... args) |
template<typename U, typename... Args>
requires (concepts::ConstructibleFrom<T, std::initializer_list<U>, Args...>) |
| constexpr | Optional (types::InPlace, std::initializer_list< U > list, Args &&... args) |
template<typename U = T>
requires (!concepts::OneOf<meta::Decay<U>, Optional, types::InPlace> && concepts::ConstructibleFrom<T, U &&>) |
| constexpr | explicit (!detail::OptionalConvertibleToWorkaround< Optional, U &&, T >) Optional(U &&value) |
| constexpr | ~Optional () |
| constexpr auto | operator= (NullOpt) -> Optional & |
| constexpr auto | operator= (Optional const &other) -> Optional &requires(concepts::Copyable< T > &&!concepts::TriviallyCopyAssignable< Storage >) |
| constexpr auto | operator= (Optional &&other) -> Optional &requires(!concepts::TriviallyMoveAssignable< Storage >) |
template<typename U = T>
requires (concepts::ConstructibleFrom<T, U> && !concepts::SameAs<meta::RemoveCVRef<U>, Optional> && (!concepts::Scalar<T> || !concepts::SameAs<meta::Decay<U>, T>) ) |
| constexpr auto | operator= (U &&value) -> Optional & |
template<typename U>
requires (concepts::ConstructibleFrom<T, U const&> && !ConstructibleFromCRefOptional<T, Optional<U>>) |
| constexpr auto | operator= (Optional< U > const &other) -> Optional & |
template<typename U>
requires (concepts::ConstructibleFrom<T, U &&> && !ConstructibleFromCRefOptional<T, Optional<U>>) |
| constexpr auto | operator= (Optional< U > &&other) -> Optional & |
| auto | clone () const -> Optional requires(concepts::Clonable< T >) |
| constexpr auto | has_value () const -> bool |
| constexpr | operator bool () const |
| constexpr auto | operator-> () -> Pointer |
| constexpr auto | operator-> () const -> ConstPointer |
| constexpr auto | operator* () &-> decltype(auto) |
| constexpr auto | operator* () const &-> decltype(auto) |
| constexpr auto | operator* () &&-> decltype(auto) |
| constexpr auto | operator* () const &&-> decltype(auto) |
| constexpr auto | value () &-> decltype(auto) |
| constexpr auto | value () const &-> decltype(auto) |
| constexpr auto | value () &&-> decltype(auto) |
| constexpr auto | value () const &&-> decltype(auto) |
template<concepts::ConvertibleTo< T > U = T>
requires (concepts::Copyable<T>) |
| constexpr auto | value_or (U &&fallback) const &-> T |
| template<concepts::ConvertibleTo< T > U = T> |
| constexpr auto | value_or (U &&fallback) &&-> T |
| constexpr auto | begin () -> Pointer |
| constexpr auto | begin () const -> ConstPointer |
| constexpr auto | end () -> Pointer |
| constexpr auto | end () const -> ConstPointer |
| constexpr auto | empty () const -> bool |
| constexpr auto | size () const -> types::size_t |
| constexpr auto | data () -> Pointer |
| constexpr auto | data () const -> ConstPointer |
| constexpr auto | front () -> Optional< Reference > |
| constexpr auto | front () const -> Optional< ConstReference > |
| constexpr auto | back () -> Optional< Reference > |
| constexpr auto | back () const -> Optional< ConstReference > |
| constexpr auto | operator[] (types::ssize_t index) -> Reference |
| constexpr auto | operator[] (types::ssize_t index) const -> ConstReference |
| constexpr auto | at (types::ssize_t index) -> Optional< Reference > |
| constexpr auto | at (types::ssize_t index) const -> Optional< ConstReference > |
| constexpr void | reset () |
| template<typename... Args> |
| constexpr auto | emplace (Args &&... args) -> decltype(auto) |
| template<concepts::InvocableTo< bool, Value const & > F> |
| constexpr auto | filter (F &&f) &&-> Optional |
| constexpr auto | __try_did_fail () &&-> NullOpt |
| constexpr auto | __try_did_succeed () &&-> Optional |
| constexpr auto | __try_move_out () &&-> T && |
| constexpr auto | transform (F &&function) &-> decltype(auto) |
| constexpr auto | and_then (F &&function) &-> decltype(auto) |
| constexpr auto | or_else (F &&function) &-> decltype(auto) |
| constexpr auto | transform_error (F &&function) &-> decltype(auto) |
|
| constexpr friend void | tag_invoke (types::Tag< util::swap >, Optional &a, Optional &b) |
template<concepts::DecaySameAs< Optional > Self, concepts::Invocable< meta::Like< Self, Value > > F, typename R = meta::InvokeResult<F, meta::Like<Self, Value>>>
requires (concepts::Optional<R>) |
| constexpr friend auto | tag_invoke (types::Tag< function::monad::bind >, Self &&self, F &&f) -> R |
| template<concepts::DecaySameAs< Optional > Self, concepts::Invocable< meta::Like< Self, Value > > F, typename R = meta::UnwrapRefDecay<meta::InvokeResult<F, meta::Like<Self, Value>>>> |
| constexpr friend auto | tag_invoke (types::Tag< function::monad::fmap >, Self &&self, F &&f) -> Optional< R > |
template<concepts::DecaySameAs< Optional > Self, concepts::InvocableTo< Optional > F>
requires (concepts::ConstructibleFrom<Optional, Self>) |
| constexpr friend auto | tag_invoke (types::Tag< function::monad::fail >, Self &&self, F &&f) -> Optional |