59#if __cplusplus >= 201103L
64#if __cplusplus >= 202002L
66# define __cpp_lib_constexpr_utility 201811L
69namespace std _GLIBCXX_VISIBILITY(default)
71_GLIBCXX_BEGIN_NAMESPACE_VERSION
78#if __cplusplus >= 201103L
95#if ! __cpp_lib_concepts
101 template <
bool,
typename _T1,
typename _T2>
104 template <
typename _U1,
typename _U2>
105 static constexpr bool _ConstructiblePair()
107 return __and_<is_constructible<_T1, const _U1&>,
111 template <
typename _U1,
typename _U2>
112 static constexpr bool _ImplicitlyConvertiblePair()
114 return __and_<is_convertible<const _U1&, _T1>,
115 is_convertible<const _U2&, _T2>>::value;
118 template <
typename _U1,
typename _U2>
119 static constexpr bool _MoveConstructiblePair()
121 return __and_<is_constructible<_T1, _U1&&>,
122 is_constructible<_T2, _U2&&>>::value;
125 template <
typename _U1,
typename _U2>
126 static constexpr bool _ImplicitlyMoveConvertiblePair()
128 return __and_<is_convertible<_U1&&, _T1>,
129 is_convertible<_U2&&, _T2>>::value;
133 template <
typename _T1,
typename _T2>
134 struct _PCC<false, _T1, _T2>
136 template <
typename _U1,
typename _U2>
137 static constexpr bool _ConstructiblePair()
142 template <
typename _U1,
typename _U2>
143 static constexpr bool _ImplicitlyConvertiblePair()
148 template <
typename _U1,
typename _U2>
149 static constexpr bool _MoveConstructiblePair()
154 template <
typename _U1,
typename _U2>
155 static constexpr bool _ImplicitlyMoveConvertiblePair()
163 template<
typename _U1,
typename _U2>
class __pair_base
165#if __cplusplus >= 201103L && ! __cpp_lib_concepts
166 template<
typename _T1,
typename _T2>
friend struct pair;
167 __pair_base() =
default;
168 ~__pair_base() =
default;
169 __pair_base(
const __pair_base&) =
default;
170 __pair_base& operator=(
const __pair_base&) =
delete;
186 template<
typename _T1,
typename _T2>
188 :
public __pair_base<_T1, _T2>
196#if __cplusplus >= 201103L
200 template<
typename... _Args1,
typename... _Args2>
205 _GLIBCXX20_CONSTEXPR
void
207 noexcept(__and_<__is_nothrow_swappable<_T1>,
208 __is_nothrow_swappable<_T2>>::value)
215#if __cplusplus > 202002L
224 noexcept(__and_v<__is_nothrow_swappable<const _T1>,
225 __is_nothrow_swappable<const _T2>>)
226 requires is_swappable_v<const _T1> && is_swappable_v<const _T2>
235 template<
typename... _Args1,
size_t... _Indexes1,
236 typename... _Args2,
size_t... _Indexes2>
238 pair(tuple<_Args1...>&, tuple<_Args2...>&,
239 _Index_tuple<_Indexes1...>, _Index_tuple<_Indexes2...>);
242#if __cpp_lib_concepts
247 explicit(__not_<__and_<__is_implicitly_default_constructible<_T1>,
248 __is_implicitly_default_constructible<_T2>>>())
250 requires is_default_constructible_v<_T1>
251 && is_default_constructible_v<_T2>
258 template<
typename _U1,
typename _U2>
259 static constexpr bool
262 if constexpr (is_constructible_v<_T1, _U1>)
263 return is_constructible_v<_T2, _U2>;
267 template<
typename _U1,
typename _U2>
268 static constexpr bool
269 _S_nothrow_constructible()
271 if constexpr (is_nothrow_constructible_v<_T1, _U1>)
272 return is_nothrow_constructible_v<_T2, _U2>;
276 template<
typename _U1,
typename _U2>
277 static constexpr bool
280 if constexpr (is_convertible_v<_U1, _T1>)
281 return is_convertible_v<_U2, _T2>;
289 constexpr explicit(!_S_convertible<const _T1&, const _T2&>())
290 pair(
const _T1& __x,
const _T2& __y)
291 noexcept(_S_nothrow_constructible<const _T1&, const _T2&>())
292 requires (_S_constructible<const _T1&, const _T2&>())
297 template<
typename _U1,
typename _U2>
298 requires (_S_constructible<_U1, _U2>())
299 constexpr explicit(!_S_convertible<_U1, _U2>())
300 pair(_U1&& __x, _U2&& __y)
301 noexcept(_S_nothrow_constructible<_U1, _U2>())
302 :
first(std::forward<_U1>(__x)),
second(std::forward<_U2>(__y))
306 template<
typename _U1,
typename _U2>
307 requires (_S_constructible<const _U1&, const _U2&>())
308 constexpr explicit(!_S_convertible<const _U1&, const _U2&>())
309 pair(
const pair<_U1, _U2>& __p)
310 noexcept(_S_nothrow_constructible<const _U1&, const _U2&>())
315 template<
typename _U1,
typename _U2>
316 requires (_S_constructible<_U1, _U2>())
317 constexpr explicit(!_S_convertible<_U1, _U2>())
318 pair(pair<_U1, _U2>&& __p)
319 noexcept(_S_nothrow_constructible<_U1, _U2>())
320 :
first(std::forward<_U1>(__p.first)),
321 second(std::forward<_U2>(__p.second))
324#if __cplusplus > 202002L
326 template<
typename _U1,
typename _U2>
327 requires (_S_constructible<_U1&, _U2&>())
328 constexpr explicit(!_S_convertible<_U1&, _U2&>())
329 pair(pair<_U1, _U2>& __p)
330 noexcept(_S_nothrow_constructible<_U1&, _U2&>())
335 template<
typename _U1,
typename _U2>
336 requires (_S_constructible<const _U1, const _U2>())
337 constexpr explicit(!_S_convertible<const _U1, const _U2>())
338 pair(
const pair<_U1, _U2>&& __p)
339 noexcept(_S_nothrow_constructible<const _U1, const _U2>())
340 :
first(std::forward<const _U1>(__p.first)),
341 second(std::forward<const _U2>(__p.second))
347 template<
typename _U1,
typename _U2>
348 static constexpr bool
351 if constexpr (is_assignable_v<_T1&, _U1>)
352 return is_assignable_v<_T2&, _U2>;
356 template<
typename _U1,
typename _U2>
357 static constexpr bool
358 _S_nothrow_assignable()
360 if constexpr (is_nothrow_assignable_v<_T1&, _U1>)
361 return is_nothrow_assignable_v<_T2&, _U2>;
368 pair& operator=(
const pair&) =
delete;
372 operator=(
const pair& __p)
373 noexcept(_S_nothrow_assignable<const _T1&, const _T2&>())
374 requires (_S_assignable<const _T1&, const _T2&>())
383 operator=(
pair&& __p)
384 noexcept(_S_nothrow_assignable<_T1, _T2>())
385 requires (_S_assignable<_T1, _T2>())
387 first = std::forward<first_type>(__p.first);
388 second = std::forward<second_type>(__p.second);
393 template<
typename _U1,
typename _U2>
395 operator=(
const pair<_U1, _U2>& __p)
396 noexcept(_S_nothrow_assignable<const _U1&, const _U2&>())
397 requires (_S_assignable<const _U1&, const _U2&>())
405 template<
typename _U1,
typename _U2>
407 operator=(pair<_U1, _U2>&& __p)
408 noexcept(_S_nothrow_assignable<_U1, _U2>())
409 requires (_S_assignable<_U1, _U2>())
411 first = std::forward<_U1>(__p.first);
412 second = std::forward<_U2>(__p.second);
416#if __cplusplus > 202002L
418 constexpr const pair&
419 operator=(
const pair& __p)
const
420 requires is_copy_assignable_v<const first_type>
421 && is_copy_assignable_v<const second_type>
429 constexpr const pair&
430 operator=(
pair&& __p)
const
431 requires is_assignable_v<const first_type&, first_type>
432 && is_assignable_v<const second_type&, second_type>
434 first = std::forward<first_type>(__p.first);
435 second = std::forward<second_type>(__p.second);
440 template<
typename _U1,
typename _U2>
441 constexpr const pair&
442 operator=(
const pair<_U1, _U2>& __p)
const
443 requires is_assignable_v<const first_type&, const _U1&>
444 && is_assignable_v<const second_type&, const _U2&>
452 template<
typename _U1,
typename _U2>
453 constexpr const pair&
454 operator=(pair<_U1, _U2>&& __p)
const
455 requires is_assignable_v<const first_type&, _U1>
456 && is_assignable_v<const second_type&, _U2>
458 first = std::forward<_U1>(__p.first);
459 second = std::forward<_U2>(__p.second);
468 template <
typename _U1 = _T1,
470 typename enable_if<__and_<
471 __is_implicitly_default_constructible<_U1>,
472 __is_implicitly_default_constructible<_U2>>
473 ::value,
bool>::type =
true>
477 template <
typename _U1 = _T1,
483 __and_<__is_implicitly_default_constructible<_U1>,
484 __is_implicitly_default_constructible<_U2>>>>
485 ::value,
bool>::type =
false>
486 explicit constexpr pair()
491 using _PCCP = _PCC<true, _T1, _T2>;
495 template<
typename _U1 = _T1,
typename _U2=_T2,
typename
496 enable_if<_PCCP::template
497 _ConstructiblePair<_U1, _U2>()
499 _ImplicitlyConvertiblePair<_U1, _U2>(),
501 constexpr pair(
const _T1& __a,
const _T2& __b)
505 template<
typename _U1 = _T1,
typename _U2=_T2,
typename
507 _ConstructiblePair<_U1, _U2>()
509 _ImplicitlyConvertiblePair<_U1, _U2>(),
511 explicit constexpr pair(
const _T1& __a,
const _T2& __b)
516 template <
typename _U1,
typename _U2>
517 using _PCCFP = _PCC<!is_same<_T1, _U1>::value
522 template<
typename _U1,
typename _U2,
typename
524 _ConstructiblePair<_U1, _U2>()
525 && _PCCFP<_U1, _U2>::template
526 _ImplicitlyConvertiblePair<_U1, _U2>(),
531 template<
typename _U1,
typename _U2,
typename
532 enable_if<_PCCFP<_U1, _U2>::template
533 _ConstructiblePair<_U1, _U2>()
534 && !_PCCFP<_U1, _U2>::template
535 _ImplicitlyConvertiblePair<_U1, _U2>(),
537 explicit constexpr pair(
const pair<_U1, _U2>& __p)
540#if _GLIBCXX_USE_DEPRECATED
541#if defined(__DEPRECATED)
542# define _GLIBCXX_DEPRECATED_PAIR_CTOR \
543 __attribute__ ((__deprecated__ ("use 'nullptr' instead of '0' to " \
544 "initialize std::pair of move-only " \
545 "type and pointer")))
547# define _GLIBCXX_DEPRECATED_PAIR_CTOR
554 struct __zero_as_null_pointer_constant
556 __zero_as_null_pointer_constant(
int __zero_as_null_pointer_constant::*)
558 template<
typename _Tp,
559 typename = __enable_if_t<is_null_pointer<_Tp>::value>>
560 __zero_as_null_pointer_constant(_Tp) =
delete;
568 template<
typename _U1,
569 __enable_if_t<__and_<__not_<is_reference<_U1>>,
571 is_constructible<_T1, _U1>,
572 __not_<is_constructible<_T1, const _U1&>>,
573 is_convertible<_U1, _T1>>::value,
575 _GLIBCXX_DEPRECATED_PAIR_CTOR
577 pair(_U1&& __x, __zero_as_null_pointer_constant, ...)
580 template<
typename _U1,
581 __enable_if_t<__and_<__not_<is_reference<_U1>>,
583 is_constructible<_T1, _U1>,
584 __not_<is_constructible<_T1, const _U1&>>,
585 __not_<is_convertible<_U1, _T1>>>::value,
587 _GLIBCXX_DEPRECATED_PAIR_CTOR
589 pair(_U1&& __x, __zero_as_null_pointer_constant, ...)
592 template<
typename _U2,
593 __enable_if_t<__and_<is_pointer<_T1>,
594 __not_<is_reference<_U2>>,
595 is_constructible<_T2, _U2>,
596 __not_<is_constructible<_T2, const _U2&>>,
597 is_convertible<_U2, _T2>>::value,
599 _GLIBCXX_DEPRECATED_PAIR_CTOR
601 pair(__zero_as_null_pointer_constant, _U2&& __y, ...)
604 template<
typename _U2,
605 __enable_if_t<__and_<is_pointer<_T1>,
606 __not_<is_reference<_U2>>,
607 is_constructible<_T2, _U2>,
608 __not_<is_constructible<_T2, const _U2&>>,
609 __not_<is_convertible<_U2, _T2>>>::value,
611 _GLIBCXX_DEPRECATED_PAIR_CTOR
613 pair(__zero_as_null_pointer_constant, _U2&& __y, ...)
615#undef _GLIBCXX_DEPRECATED_PAIR_CTOR
618 template<
typename _U1,
typename _U2,
typename
619 enable_if<_PCCP::template
620 _MoveConstructiblePair<_U1, _U2>()
622 _ImplicitlyMoveConvertiblePair<_U1, _U2>(),
624 constexpr pair(_U1&& __x, _U2&& __y)
627 template<
typename _U1,
typename _U2,
typename
628 enable_if<_PCCP::template
629 _MoveConstructiblePair<_U1, _U2>()
631 _ImplicitlyMoveConvertiblePair<_U1, _U2>(),
633 explicit constexpr pair(_U1&& __x, _U2&& __y)
637 template<
typename _U1,
typename _U2,
typename
638 enable_if<_PCCFP<_U1, _U2>::template
639 _MoveConstructiblePair<_U1, _U2>()
640 && _PCCFP<_U1, _U2>::template
641 _ImplicitlyMoveConvertiblePair<_U1, _U2>(),
643 constexpr pair(pair<_U1, _U2>&& __p)
647 template<
typename _U1,
typename _U2,
typename
648 enable_if<_PCCFP<_U1, _U2>::template
649 _MoveConstructiblePair<_U1, _U2>()
650 && !_PCCFP<_U1, _U2>::template
651 _ImplicitlyMoveConvertiblePair<_U1, _U2>(),
653 explicit constexpr pair(pair<_U1, _U2>&& __p)
658 operator=(__conditional_t<__and_<is_copy_assignable<_T1>,
659 is_copy_assignable<_T2>>::value,
660 const pair&,
const __nonesuch&> __p)
668 operator=(__conditional_t<__and_<is_move_assignable<_T1>,
669 is_move_assignable<_T2>>::value,
670 pair&&, __nonesuch&&> __p)
671 noexcept(__and_<is_nothrow_move_assignable<_T1>,
672 is_nothrow_move_assignable<_T2>>::value)
674 first = std::forward<first_type>(__p.first);
675 second = std::forward<second_type>(__p.second);
679 template<
typename _U1,
typename _U2>
680 typename enable_if<__and_<is_assignable<_T1&, const _U1&>,
681 is_assignable<_T2&, const _U2&>>::value,
683 operator=(
const pair<_U1, _U2>& __p)
690 template<
typename _U1,
typename _U2>
691 typename enable_if<__and_<is_assignable<_T1&, _U1&&>,
692 is_assignable<_T2&, _U2&&>>::value,
694 operator=(pair<_U1, _U2>&& __p)
696 first = std::forward<_U1>(__p.first);
697 second = std::forward<_U2>(__p.second);
711 pair(
const _T1& __a,
const _T2& __b)
715 template<
typename _U1,
typename _U2>
716 pair(
const pair<_U1, _U2>& __p)
723#if __cpp_deduction_guides >= 201606
728 template<
typename _T1,
typename _T2>
729 inline _GLIBCXX_CONSTEXPR
bool
733#if __cpp_lib_three_way_comparison && __cpp_lib_concepts
734 template<
typename _T1,
typename _T2>
735 constexpr common_comparison_category_t<__detail::__synth3way_t<_T1>,
736 __detail::__synth3way_t<_T2>>
739 if (
auto __c = __detail::__synth3way(__x.
first, __y.
first); __c != 0)
751 template<
typename _T1,
typename _T2>
752 inline _GLIBCXX_CONSTEXPR
bool
758 template<
typename _T1,
typename _T2>
759 inline _GLIBCXX_CONSTEXPR
bool
761 {
return !(__x == __y); }
764 template<
typename _T1,
typename _T2>
765 inline _GLIBCXX_CONSTEXPR
bool
767 {
return __y < __x; }
770 template<
typename _T1,
typename _T2>
771 inline _GLIBCXX_CONSTEXPR
bool
773 {
return !(__y < __x); }
776 template<
typename _T1,
typename _T2>
777 inline _GLIBCXX_CONSTEXPR
bool
779 {
return !(__x < __y); }
782#if __cplusplus >= 201103L
788 template<
typename _T1,
typename _T2>
789 _GLIBCXX20_CONSTEXPR
inline
790#if __cplusplus > 201402L || !defined(__STRICT_ANSI__)
793 __is_swappable<_T2>>::value>::type
798 noexcept(
noexcept(__x.
swap(__y)))
801#if __cplusplus > 202002L
802 template<
typename _T1,
typename _T2>
803 requires is_swappable_v<const _T1> && is_swappable_v<const _T2>
806 noexcept(
noexcept(__x.
swap(__y)))
810#if __cplusplus > 201402L || !defined(__STRICT_ANSI__)
811 template<
typename _T1,
typename _T2>
812 typename enable_if<!__and_<__is_swappable<_T1>,
813 __is_swappable<_T2>>::value>::type
814 swap(pair<_T1, _T2>&, pair<_T1, _T2>&) =
delete;
835#if __cplusplus >= 201103L
837 template<
typename _T1,
typename _T2>
838 constexpr pair<typename __decay_and_strip<_T1>::__type,
839 typename __decay_and_strip<_T2>::__type>
842 typedef typename __decay_and_strip<_T1>::__type __ds_type1;
843 typedef typename __decay_and_strip<_T2>::__type __ds_type2;
845 return __pair_type(std::forward<_T1>(__x), std::forward<_T2>(__y));
848 template<
typename _T1,
typename _T2>
850 make_pair(_T1 __x, _T2 __y)
856#if __cplusplus >= 201103L
860 template<
typename _T1,
typename _T2>
861 struct __is_tuple_like_impl<pair<_T1, _T2>> :
true_type
866 template<
class _Tp1,
class _Tp2>
871 template<
class _Tp1,
class _Tp2>
873 {
typedef _Tp1 type; };
876 template<
class _Tp1,
class _Tp2>
878 {
typedef _Tp2 type; };
880#if __cplusplus >= 201703L
881 template<
typename _Tp1,
typename _Tp2>
882 inline constexpr size_t tuple_size_v<pair<_Tp1, _Tp2>> = 2;
884 template<
typename _Tp1,
typename _Tp2>
885 inline constexpr size_t tuple_size_v<const pair<_Tp1, _Tp2>> = 2;
887 template<
typename _Tp>
888 inline constexpr bool __is_pair =
false;
890 template<
typename _Tp,
typename _Up>
891 inline constexpr bool __is_pair<pair<_Tp, _Up>> =
true;
893 template<
typename _Tp,
typename _Up>
894 inline constexpr bool __is_pair<const pair<_Tp, _Up>> =
true;
898 template<
size_t _Int>
904 template<
typename _Tp1,
typename _Tp2>
905 static constexpr _Tp1&
907 {
return __pair.first; }
909 template<
typename _Tp1,
typename _Tp2>
910 static constexpr _Tp1&&
911 __move_get(pair<_Tp1, _Tp2>&& __pair)
noexcept
912 {
return std::forward<_Tp1>(__pair.first); }
914 template<
typename _Tp1,
typename _Tp2>
915 static constexpr const _Tp1&
916 __const_get(
const pair<_Tp1, _Tp2>& __pair)
noexcept
917 {
return __pair.first; }
919 template<
typename _Tp1,
typename _Tp2>
920 static constexpr const _Tp1&&
921 __const_move_get(
const pair<_Tp1, _Tp2>&& __pair)
noexcept
922 {
return std::forward<const _Tp1>(__pair.first); }
928 template<
typename _Tp1,
typename _Tp2>
929 static constexpr _Tp2&
930 __get(pair<_Tp1, _Tp2>& __pair)
noexcept
931 {
return __pair.second; }
933 template<
typename _Tp1,
typename _Tp2>
934 static constexpr _Tp2&&
935 __move_get(pair<_Tp1, _Tp2>&& __pair)
noexcept
936 {
return std::forward<_Tp2>(__pair.second); }
938 template<
typename _Tp1,
typename _Tp2>
939 static constexpr const _Tp2&
940 __const_get(
const pair<_Tp1, _Tp2>& __pair)
noexcept
941 {
return __pair.second; }
943 template<
typename _Tp1,
typename _Tp2>
944 static constexpr const _Tp2&&
945 __const_move_get(
const pair<_Tp1, _Tp2>&& __pair)
noexcept
946 {
return std::forward<const _Tp2>(__pair.second); }
954 template<
size_t _Int,
class _Tp1,
class _Tp2>
955 constexpr typename tuple_element<_Int, pair<_Tp1, _Tp2>>::type&
957 {
return __pair_get<_Int>::__get(__in); }
959 template<
size_t _Int,
class _Tp1,
class _Tp2>
960 constexpr typename tuple_element<_Int, pair<_Tp1, _Tp2>>::type&&
962 {
return __pair_get<_Int>::__move_get(
std::move(__in)); }
964 template<
size_t _Int,
class _Tp1,
class _Tp2>
965 constexpr const typename tuple_element<_Int, pair<_Tp1, _Tp2>>::type&
967 {
return __pair_get<_Int>::__const_get(__in); }
969 template<
size_t _Int,
class _Tp1,
class _Tp2>
970 constexpr const typename tuple_element<_Int, pair<_Tp1, _Tp2>>::type&&
972 {
return __pair_get<_Int>::__const_move_get(
std::move(__in)); }
974#if __cplusplus >= 201402L
976#define __cpp_lib_tuples_by_type 201304L
978 template <
typename _Tp,
typename _Up>
981 {
return __p.first; }
983 template <
typename _Tp,
typename _Up>
986 {
return __p.first; }
988 template <
typename _Tp,
typename _Up>
993 template <
typename _Tp,
typename _Up>
994 constexpr const _Tp&&
998 template <
typename _Tp,
typename _Up>
1001 {
return __p.second; }
1003 template <
typename _Tp,
typename _Up>
1004 constexpr const _Tp&
1006 {
return __p.second; }
1008 template <
typename _Tp,
typename _Up>
1013 template <
typename _Tp,
typename _Up>
1014 constexpr const _Tp&&
1018#if __cplusplus > 202002L
1019 template<
typename _T1,
typename _T2,
typename _U1,
typename _U2,
1020 template<
typename>
class _TQual,
template<
typename>
class _UQual>
1021 requires requires {
typename pair<common_reference_t<_TQual<_T1>, _UQual<_U1>>,
1022 common_reference_t<_TQual<_T2>, _UQual<_U2>>>; }
1023 struct basic_common_reference<pair<_T1, _T2>, pair<_U1, _U2>, _TQual, _UQual>
1025 using type = pair<common_reference_t<_TQual<_T1>, _UQual<_U1>>,
1026 common_reference_t<_TQual<_T2>, _UQual<_U2>>>;
1029 template<
typename _T1,
typename _T2,
typename _U1,
typename _U2>
1030 requires requires {
typename pair<common_type_t<_T1, _U1>, common_type_t<_T2, _U2>>; }
1031 struct common_type<pair<_T1, _T2>, pair<_U1, _U2>>
1032 {
using type = pair<common_type_t<_T1, _U1>, common_type_t<_T2, _U2>>; };
1039_GLIBCXX_END_NAMESPACE_VERSION
integral_constant< bool, true > true_type
The type used as a compile-time boolean with true value.
pair(_T1, _T2) -> pair< _T1, _T2 >
Two pairs of the same type are equal iff their members are equal.
constexpr bool operator>(const pair< _T1, _T2 > &__x, const pair< _T1, _T2 > &__y)
Uses operator< to find the result.
constexpr bool operator!=(const pair< _T1, _T2 > &__x, const pair< _T1, _T2 > &__y)
Uses operator== to find the result.
constexpr bool operator==(const pair< _T1, _T2 > &__x, const pair< _T1, _T2 > &__y)
Two pairs of the same type are equal iff their members are equal.
constexpr bool operator>=(const pair< _T1, _T2 > &__x, const pair< _T1, _T2 > &__y)
Uses operator< to find the result.
constexpr std::remove_reference< _Tp >::type && move(_Tp &&__t) noexcept
Convert a value to an rvalue.
constexpr enable_if< __and_< __is_swappable< _T1 >, __is_swappable< _T2 > >::value >::type swap(pair< _T1, _T2 > &__x, pair< _T1, _T2 > &__y) noexcept(noexcept(__x.swap(__y)))
constexpr piecewise_construct_t piecewise_construct
Tag for piecewise construction of std::pair objects.
constexpr pair< typename __decay_and_strip< _T1 >::__type, typename __decay_and_strip< _T2 >::__type > make_pair(_T1 &&__x, _T2 &&__y)
A convenience wrapper for creating a pair from two objects.
void swap(any &__x, any &__y) noexcept
Exchange the states of two any objects.
constexpr _Tp && forward(typename std::remove_reference< _Tp >::type &__t) noexcept
Forward an lvalue.
ISO C++ entities toplevel namespace is std.
Primary class template, tuple.
Define a member typedef type only if a boolean constant is true.
Struct holding two objects of arbitrary type.
constexpr pair(const _T1 &__a, const _T2 &__b)
Construct from two const lvalues, allowing implicit conversions.
_T1 first
The first member.
_T1 first_type
The type of the first member.
constexpr void swap(pair &__p) noexcept(__and_< __is_nothrow_swappable< _T1 >, __is_nothrow_swappable< _T2 > >::value)
Swap the first members and then the second members.
constexpr pair(const pair &)=default
Copy constructor.
_T2 second_type
The type of the second member.
constexpr pair(pair &&)=default
Move constructor.
_T2 second
The second member.
Tag type for piecewise construction of std::pair objects.
Finds the size of a given tuple type.
Gives the type of the ith element of a given tuple type.