• Home
  • Raw
  • Download

Lines Matching refs:expected

54     class expected;  variable
86 class _NODISCARD_ expected {
93 using rebind = expected<U, error_type>;
96 constexpr expected() = default;
97 constexpr expected(const expected& rhs) = default;
98 constexpr expected(expected&& rhs) noexcept = default;
103 !std::is_constructible_v<T, expected<U, G>&> &&
104 !std::is_constructible_v<T, expected<U, G>&&> &&
105 !std::is_constructible_v<T, const expected<U, G>&> &&
106 !std::is_constructible_v<T, const expected<U, G>&&> &&
107 !std::is_convertible_v<expected<U, G>&, T> &&
108 !std::is_convertible_v<expected<U, G>&&, T> &&
109 !std::is_convertible_v<const expected<U, G>&, T> &&
110 !std::is_convertible_v<const expected<U, G>&&, T> &&
115 constexpr expected(const expected<U, G>& rhs) { in expected() function
123 !std::is_constructible_v<T, expected<U, G>&> &&
124 !std::is_constructible_v<T, expected<U, G>&&> &&
125 !std::is_constructible_v<T, const expected<U, G>&> &&
126 !std::is_constructible_v<T, const expected<U, G>&&> &&
127 !std::is_convertible_v<expected<U, G>&, T> &&
128 !std::is_convertible_v<expected<U, G>&&, T> &&
129 !std::is_convertible_v<const expected<U, G>&, T> &&
130 !std::is_convertible_v<const expected<U, G>&&, T> &&
134 constexpr explicit expected(const expected<U, G>& rhs) { in expected() function
142 !std::is_constructible_v<T, expected<U, G>&> &&
143 !std::is_constructible_v<T, expected<U, G>&&> &&
144 !std::is_constructible_v<T, const expected<U, G>&> &&
145 !std::is_constructible_v<T, const expected<U, G>&&> &&
146 !std::is_convertible_v<expected<U, G>&, T> &&
147 !std::is_convertible_v<expected<U, G>&&, T> &&
148 !std::is_convertible_v<const expected<U, G>&, T> &&
149 !std::is_convertible_v<const expected<U, G>&&, T> &&
154 constexpr expected(expected<U, G>&& rhs) { in expected() function
162 !std::is_constructible_v<T, expected<U, G>&> &&
163 !std::is_constructible_v<T, expected<U, G>&&> &&
164 !std::is_constructible_v<T, const expected<U, G>&> &&
165 !std::is_constructible_v<T, const expected<U, G>&&> &&
166 !std::is_convertible_v<expected<U, G>&, T> &&
167 !std::is_convertible_v<expected<U, G>&&, T> &&
168 !std::is_convertible_v<const expected<U, G>&, T> &&
169 !std::is_convertible_v<const expected<U, G>&&, T> &&
173 constexpr explicit expected(expected<U, G>&& rhs) { in expected() function
181 !std::is_same_v<expected<T, E>, std::remove_cv_t<std::remove_reference_t<U>>> &&
186 constexpr expected(U&& v) : var_(std::in_place_index<0>, std::forward<U>(v)) {} in expected() function
191 !std::is_same_v<expected<T, E>, std::remove_cv_t<std::remove_reference_t<U>>> &&
196 constexpr explicit expected(U&& v) : var_(std::in_place_index<0>, T(std::forward<U>(v))) {} in expected() function
203 constexpr expected(const unexpected<G>& e) in expected() function
210 constexpr explicit expected(const unexpected<G>& e) in expected() function
218 constexpr expected(unexpected<G>&& e) in expected() function
225 constexpr explicit expected(unexpected<G>&& e) in expected() function
231 constexpr explicit expected(std::in_place_t, Args&&... args) in expected() function
237 constexpr explicit expected(std::in_place_t, std::initializer_list<U> il, Args&&... args) in expected() function
243 constexpr explicit expected(unexpect_t, Args&&... args) in expected() function
249 constexpr explicit expected(unexpect_t, std::initializer_list<U> il, Args&&... args) in expected() function
253 ~expected() = default;
262 expected& operator=(const expected& rhs) = default;
265 expected& operator=(expected&& rhs) noexcept(
270 !std::is_same_v<expected<T, E>, std::remove_cv_t<std::remove_reference_t<U>>> &&
274 expected& operator=(U&& rhs) {
280 expected& operator=(const unexpected<G>& rhs) {
289 expected& operator=(unexpected<G>&& rhs) {
299 expected(std::in_place, std::forward<Args>(args)...).swap(*this); in emplace()
307 expected(std::in_place, il, std::forward<Args>(args)...).swap(*this); in emplace()
317 void swap(expected& rhs) noexcept( in swap()
366 friend constexpr bool operator==(const expected<T1, E1>& x, const expected<T2, E2>& y);
368 friend constexpr bool operator!=(const expected<T1, E1>& x, const expected<T2, E2>& y);
372 friend constexpr bool operator==(const expected<T1, E1>&, const unexpected<E2>&);
374 friend constexpr bool operator==(const unexpected<E2>&, const expected<T1, E1>&);
376 friend constexpr bool operator!=(const expected<T1, E1>&, const unexpected<E2>&);
378 friend constexpr bool operator!=(const unexpected<E2>&, const expected<T1, E1>&);
382 friend void swap(expected<T1, E1>& x, expected<T1, E1>& y) noexcept(noexcept(x.swap(y)));
389 constexpr bool operator==(const expected<T1, E1>& x, const expected<T2, E2>& y) {
396 constexpr bool operator!=(const expected<T1, E1>& x, const expected<T2, E2>& y) {
402 constexpr bool operator==(const expected<T1, E1>& x, const unexpected<E2>& y) {
406 constexpr bool operator==(const unexpected<E2>& x, const expected<T1, E1>& y) {
410 constexpr bool operator!=(const expected<T1, E1>& x, const unexpected<E2>& y) {
414 constexpr bool operator!=(const unexpected<E2>& x, const expected<T1, E1>& y) {
419 void swap(expected<T1, E1>& x, expected<T1, E1>& y) noexcept(noexcept(x.swap(y))) { in swap()
424 class _NODISCARD_ expected<void, E> {
431 constexpr expected() = default;
432 constexpr expected(const expected& rhs) = default;
433 constexpr expected(expected&& rhs) noexcept = default;
440 constexpr expected(const expected<U, G>& rhs) { in expected() function
448 constexpr explicit expected(const expected<U, G>& rhs) { in expected() function
457 constexpr expected(expected<U, G>&& rhs) { in expected() function
465 constexpr explicit expected(expected<U, G>&& rhs) { in expected() function
474 constexpr expected(const unexpected<G>& e) in expected() function
481 constexpr explicit expected(const unexpected<G>& e) in expected() function
489 constexpr expected(unexpected<G>&& e) in expected() function
496 constexpr explicit expected(unexpected<G>&& e) in expected() function
502 constexpr explicit expected(std::in_place_t, Args&&...) {} in expected() function
507 constexpr explicit expected(unexpect_t, Args&&... args) in expected() function
513 constexpr explicit expected(unexpect_t, std::initializer_list<U> il, Args&&... args) in expected() function
517 ~expected() = default;
526 expected& operator=(const expected& rhs) = default;
529 expected& operator=(expected&& rhs) noexcept(std::is_nothrow_move_assignable_v<E>) = default;
532 expected& operator=(const unexpected<G>& rhs) {
541 expected& operator=(unexpected<G>&& rhs) {
555 void swap(expected& rhs) noexcept(std::is_nothrow_move_constructible_v<E>) { in swap()
572 friend constexpr bool operator==(const expected<void, E1>& x, const expected<void, E2>& y);
576 friend void swap(expected<T1, E1>& x, expected<T1, E1>& y) noexcept(noexcept(x.swap(y)));
583 constexpr bool operator==(const expected<void, E1>& x, const expected<void, E2>& y) {
590 constexpr bool operator==(const expected<T1, E1>& x, const expected<void, E2>& y) {
597 constexpr bool operator==(const expected<void, E1>& x, const expected<T2, E2>& y) {