29 #ifndef _GLIBCXX_TYPE_TRAITS
30 #define _GLIBCXX_TYPE_TRAITS 1
32 #pragma GCC system_header
34 #if __cplusplus < 201103L
40 namespace std _GLIBCXX_VISIBILITY(default)
42 _GLIBCXX_BEGIN_NAMESPACE_VERSION
56 template<
typename _Tp, _Tp __v>
59 static constexpr _Tp value = __v;
60 typedef _Tp value_type;
62 constexpr
operator value_type()
const {
return value; }
63 #if __cplusplus > 201103L
64 constexpr value_type operator()()
const {
return value; }
68 template<
typename _Tp, _Tp __v>
79 template<
bool,
typename,
typename>
90 template<
typename _B1>
95 template<
typename _B1,
typename _B2>
96 struct __or_<_B1, _B2>
97 :
public conditional<_B1::value, _B1, _B2>::type
100 template<
typename _B1,
typename _B2,
typename _B3,
typename... _Bn>
101 struct __or_<_B1, _B2, _B3, _Bn...>
102 :
public conditional<_B1::value, _B1, __or_<_B2, _B3, _Bn...>>::type
105 template<
typename...>
113 template<
typename _B1>
118 template<
typename _B1,
typename _B2>
119 struct __and_<_B1, _B2>
120 :
public conditional<_B1::value, _B2, _B1>::type
123 template<
typename _B1,
typename _B2,
typename _B3,
typename... _Bn>
124 struct __and_<_B1, _B2, _B3, _Bn...>
125 :
public conditional<_B1::value, __and_<_B2, _B3, _Bn...>, _B1>::type
128 template<
typename _Pp>
130 :
public integral_constant<bool, !_Pp::value>
138 template<
typename _Tp>
139 struct __success_type
140 {
typedef _Tp type; };
142 struct __failure_type
151 struct __is_void_helper
155 struct __is_void_helper<void>
159 template<
typename _Tp>
161 :
public __is_void_helper<typename remove_cv<_Tp>::type>
::type
165 struct __is_integral_helper
169 struct __is_integral_helper<bool>
173 struct __is_integral_helper<char>
177 struct __is_integral_helper<signed char>
181 struct __is_integral_helper<unsigned char>
184 #ifdef _GLIBCXX_USE_WCHAR_T
186 struct __is_integral_helper<wchar_t>
191 struct __is_integral_helper<char16_t>
195 struct __is_integral_helper<char32_t>
199 struct __is_integral_helper<short>
203 struct __is_integral_helper<unsigned short>
207 struct __is_integral_helper<int>
211 struct __is_integral_helper<unsigned int>
215 struct __is_integral_helper<long>
219 struct __is_integral_helper<unsigned long>
223 struct __is_integral_helper<long long>
227 struct __is_integral_helper<unsigned long long>
230 #if !defined(__STRICT_ANSI__) && defined(_GLIBCXX_USE_INT128)
232 struct __is_integral_helper<__int128>
236 struct __is_integral_helper<unsigned __int128>
241 template<
typename _Tp>
243 :
public __is_integral_helper<typename remove_cv<_Tp>::type>
::type
247 struct __is_floating_point_helper
251 struct __is_floating_point_helper<float>
255 struct __is_floating_point_helper<double>
259 struct __is_floating_point_helper<long double>
262 #if !defined(__STRICT_ANSI__) && defined(_GLIBCXX_USE_FLOAT128)
264 struct __is_floating_point_helper<__float128>
269 template<
typename _Tp>
271 :
public __is_floating_point_helper<typename remove_cv<_Tp>::type>::type
279 template<
typename _Tp, std::
size_t _Size>
283 template<
typename _Tp>
284 struct is_array<_Tp[]>
288 struct __is_pointer_helper
291 template<
typename _Tp>
292 struct __is_pointer_helper<_Tp*>
296 template<
typename _Tp>
298 :
public __is_pointer_helper<typename remove_cv<_Tp>::type>::type
306 template<
typename _Tp>
315 template<
typename _Tp>
323 struct __is_member_object_pointer_helper
326 template<
typename _Tp,
typename _Cp>
327 struct __is_member_object_pointer_helper<_Tp _Cp::*>
331 template<
typename _Tp>
333 :
public __is_member_object_pointer_helper<
334 typename remove_cv<_Tp>::type>::type
338 struct __is_member_function_pointer_helper
341 template<
typename _Tp,
typename _Cp>
342 struct __is_member_function_pointer_helper<_Tp _Cp::*>
343 :
public integral_constant<bool, is_function<_Tp>::value> { };
346 template<
typename _Tp>
348 :
public __is_member_function_pointer_helper<
349 typename remove_cv<_Tp>::type>
::type
353 template<
typename _Tp>
359 template<
typename _Tp>
365 template<
typename _Tp>
375 template<
typename _Res,
typename... _ArgTypes>
376 struct is_function<_Res(_ArgTypes...)>
379 template<
typename _Res,
typename... _ArgTypes>
380 struct is_function<_Res(_ArgTypes...) &>
383 template<
typename _Res,
typename... _ArgTypes>
384 struct is_function<_Res(_ArgTypes...) &&>
387 template<
typename _Res,
typename... _ArgTypes>
388 struct is_function<_Res(_ArgTypes......)>
391 template<
typename _Res,
typename... _ArgTypes>
392 struct is_function<_Res(_ArgTypes......) &>
395 template<
typename _Res,
typename... _ArgTypes>
396 struct is_function<_Res(_ArgTypes......) &&>
399 template<
typename _Res,
typename... _ArgTypes>
400 struct is_function<_Res(_ArgTypes...) const>
403 template<
typename _Res,
typename... _ArgTypes>
404 struct is_function<_Res(_ArgTypes...) const &>
407 template<
typename _Res,
typename... _ArgTypes>
408 struct is_function<_Res(_ArgTypes...) const &&>
411 template<
typename _Res,
typename... _ArgTypes>
412 struct is_function<_Res(_ArgTypes......) const>
415 template<
typename _Res,
typename... _ArgTypes>
416 struct is_function<_Res(_ArgTypes......) const &>
419 template<
typename _Res,
typename... _ArgTypes>
420 struct is_function<_Res(_ArgTypes......) const &&>
423 template<
typename _Res,
typename... _ArgTypes>
424 struct is_function<_Res(_ArgTypes...) volatile>
427 template<
typename _Res,
typename... _ArgTypes>
428 struct is_function<_Res(_ArgTypes...) volatile &>
431 template<
typename _Res,
typename... _ArgTypes>
432 struct is_function<_Res(_ArgTypes...) volatile &&>
435 template<
typename _Res,
typename... _ArgTypes>
436 struct is_function<_Res(_ArgTypes......) volatile>
439 template<
typename _Res,
typename... _ArgTypes>
440 struct is_function<_Res(_ArgTypes......) volatile &>
443 template<
typename _Res,
typename... _ArgTypes>
444 struct is_function<_Res(_ArgTypes......) volatile &&>
447 template<
typename _Res,
typename... _ArgTypes>
448 struct is_function<_Res(_ArgTypes...) const volatile>
451 template<
typename _Res,
typename... _ArgTypes>
452 struct is_function<_Res(_ArgTypes...) const volatile &>
455 template<
typename _Res,
typename... _ArgTypes>
456 struct is_function<_Res(_ArgTypes...) const volatile &&>
459 template<
typename _Res,
typename... _ArgTypes>
460 struct is_function<_Res(_ArgTypes......) const volatile>
463 template<
typename _Res,
typename... _ArgTypes>
464 struct is_function<_Res(_ArgTypes......) const volatile &>
467 template<
typename _Res,
typename... _ArgTypes>
468 struct is_function<_Res(_ArgTypes......) const volatile &&>
472 struct __is_null_pointer_helper
476 struct __is_null_pointer_helper<std::nullptr_t>
480 template<
typename _Tp>
482 :
public __is_null_pointer_helper<typename remove_cv<_Tp>::type>::type
486 template<
typename _Tp>
494 template<
typename _Tp>
496 :
public __or_<is_lvalue_reference<_Tp>,
497 is_rvalue_reference<_Tp>>::type
501 template<
typename _Tp>
503 :
public __or_<is_integral<_Tp>, is_floating_point<_Tp>>::type
507 template<
typename _Tp>
509 :
public __or_<is_arithmetic<_Tp>, is_void<_Tp>,
510 is_null_pointer<_Tp>>::type
514 template<
typename _Tp>
516 :
public __not_<__or_<is_function<_Tp>, is_reference<_Tp>,
524 template<
typename _Tp>
526 :
public __or_<is_arithmetic<_Tp>, is_enum<_Tp>, is_pointer<_Tp>,
527 is_member_pointer<_Tp>, is_null_pointer<_Tp>>::type
531 template<
typename _Tp>
535 template<
typename _Tp>
536 struct __is_member_pointer_helper
539 template<
typename _Tp,
typename _Cp>
540 struct __is_member_pointer_helper<_Tp _Cp::*>
544 template<
typename _Tp>
545 struct is_member_pointer
546 :
public __is_member_pointer_helper<typename remove_cv<_Tp>::type>::type
551 template<
typename _Tp>
552 struct __is_referenceable
553 :
public __or_<is_object<_Tp>, is_reference<_Tp>>::type
556 template<
typename _Res,
typename... _Args>
557 struct __is_referenceable<_Res(_Args...)>
561 template<
typename _Res,
typename... _Args>
562 struct __is_referenceable<_Res(_Args......)>
573 template<
typename _Tp>
582 template<
typename _Tp>
587 template<
typename _Tp>
595 template<
typename _Tp>
602 template<
typename _Tp>
608 template<
typename _Tp>
614 template<
typename _Tp>
620 template<
typename _Tp>
626 template<
typename _Tp>
631 template<
typename _Tp,
633 struct __is_signed_helper
636 template<
typename _Tp>
637 struct __is_signed_helper<_Tp, true>
638 :
public integral_constant<bool, _Tp(-1) < _Tp(0)>
642 template<typename _Tp>
644 : public __is_signed_helper<_Tp>::type
648 template<typename _Tp>
650 : public __and_<is_arithmetic<_Tp>, __not_<is_signed<_Tp>>>::type
657 struct add_rvalue_reference;
663 template<typename _Tp>
664 typename add_rvalue_reference<_Tp>::type declval() noexcept;
666 template<typename, unsigned = 0>
670 struct remove_all_extents;
672 template<typename _Tp>
673 struct __is_array_known_bounds
674 : public integral_constant<bool, (extent<_Tp>::value > 0)>
677 template<
typename _Tp>
678 struct __is_array_unknown_bounds
679 :
public __and_<is_array<_Tp>, __not_<extent<_Tp>>>::type
687 struct __do_is_destructible_impl
689 template<
typename _Tp,
typename = decltype(declval<_Tp&>().~_Tp())>
696 template<
typename _Tp>
697 struct __is_destructible_impl
698 :
public __do_is_destructible_impl
700 typedef decltype(__test<_Tp>(0)) type;
703 template<typename _Tp,
704 bool = __or_<is_void<_Tp>,
705 __is_array_unknown_bounds<_Tp>,
706 is_function<_Tp>>::value,
707 bool = __or_<is_reference<_Tp>, is_scalar<_Tp>>::value>
708 struct __is_destructible_safe;
710 template<typename _Tp>
711 struct __is_destructible_safe<_Tp, false, false>
712 : public __is_destructible_impl<typename
713 remove_all_extents<_Tp>::type>::type
716 template<
typename _Tp>
717 struct __is_destructible_safe<_Tp, true, false>
720 template<
typename _Tp>
721 struct __is_destructible_safe<_Tp, false, true>
725 template<
typename _Tp>
726 struct is_destructible
727 :
public __is_destructible_safe<_Tp>::type
734 struct __do_is_nt_destructible_impl
736 template<
typename _Tp>
737 static integral_constant<bool, noexcept(declval<_Tp&>().~_Tp())>
744 template<
typename _Tp>
745 struct __is_nt_destructible_impl
746 :
public __do_is_nt_destructible_impl
748 typedef decltype(__test<_Tp>(0)) type;
751 template<typename _Tp,
752 bool = __or_<is_void<_Tp>,
753 __is_array_unknown_bounds<_Tp>,
754 is_function<_Tp>>::value,
755 bool = __or_<is_reference<_Tp>, is_scalar<_Tp>>::value>
756 struct __is_nt_destructible_safe;
758 template<typename _Tp>
759 struct __is_nt_destructible_safe<_Tp, false, false>
760 : public __is_nt_destructible_impl<typename
761 remove_all_extents<_Tp>::type>::type
764 template<
typename _Tp>
765 struct __is_nt_destructible_safe<_Tp, true, false>
768 template<
typename _Tp>
769 struct __is_nt_destructible_safe<_Tp, false, true>
773 template<
typename _Tp>
774 struct is_nothrow_destructible
775 :
public __is_nt_destructible_safe<_Tp>::type
778 struct __do_is_default_constructible_impl
780 template<
typename _Tp,
typename = decltype(_Tp())>
787 template<
typename _Tp>
788 struct __is_default_constructible_impl
789 :
public __do_is_default_constructible_impl
791 typedef decltype(__test<_Tp>(0)) type;
794 template<typename _Tp>
795 struct __is_default_constructible_atom
796 : public __and_<__not_<is_void<_Tp>>,
797 __is_default_constructible_impl<_Tp>>::type
800 template<typename _Tp, bool = is_array<_Tp>::value>
801 struct __is_default_constructible_safe;
808 template<
typename _Tp>
809 struct __is_default_constructible_safe<_Tp, true>
810 :
public __and_<__is_array_known_bounds<_Tp>,
811 __is_default_constructible_atom<typename
812 remove_all_extents<_Tp>::type>>::type
815 template<
typename _Tp>
816 struct __is_default_constructible_safe<_Tp, false>
817 :
public __is_default_constructible_atom<_Tp>::type
821 template<
typename _Tp>
822 struct is_default_constructible
823 :
public __is_default_constructible_safe<_Tp>::type
838 struct __do_is_static_castable_impl
840 template<
typename _From,
typename _To,
typename
841 = decltype(static_cast<_To>(declval<_From>()))>
844 template<
typename,
typename>
848 template<
typename _From,
typename _To>
849 struct __is_static_castable_impl
850 :
public __do_is_static_castable_impl
852 typedef decltype(__test<_From, _To>(0)) type;
855 template<typename _From, typename _To>
856 struct __is_static_castable_safe
857 : public __is_static_castable_impl<_From, _To>::type
861 template<
typename _From,
typename _To>
862 struct __is_static_castable
863 :
public integral_constant<bool, (__is_static_castable_safe<
872 struct __do_is_direct_constructible_impl
874 template<
typename _Tp,
typename _Arg,
typename
875 = decltype(::
new _Tp(declval<_Arg>()))>
878 template<
typename,
typename>
882 template<
typename _Tp,
typename _Arg>
883 struct __is_direct_constructible_impl
884 :
public __do_is_direct_constructible_impl
886 typedef decltype(__test<_Tp, _Arg>(0)) type;
889 template<typename _Tp, typename _Arg>
890 struct __is_direct_constructible_new_safe
891 : public __and_<is_destructible<_Tp>,
892 __is_direct_constructible_impl<_Tp, _Arg>>::type
895 template<
typename,
typename>
898 template<
typename,
typename>
902 struct remove_reference;
904 template<
typename _From,
typename _To,
bool
905 = __not_<__or_<is_void<_From>,
906 is_function<_From>>>::value>
907 struct __is_base_to_derived_ref;
911 template<
typename _From,
typename _To>
912 struct __is_base_to_derived_ref<_From, _To, true>
914 typedef typename remove_cv<
typename remove_reference<_From
915 >::type>::type __src_t;
916 typedef typename remove_cv<
typename remove_reference<_To
917 >::type>::type __dst_t;
918 typedef __and_<__not_<is_same<__src_t, __dst_t>>,
919 is_base_of<__src_t, __dst_t>> type;
920 static constexpr
bool value = type::value;
923 template<
typename _From,
typename _To>
924 struct __is_base_to_derived_ref<_From, _To, false>
928 template<
typename _From,
typename _To,
bool
929 = __and_<is_lvalue_reference<_From>,
930 is_rvalue_reference<_To>>::value>
931 struct __is_lvalue_to_rvalue_ref;
935 template<
typename _From,
typename _To>
936 struct __is_lvalue_to_rvalue_ref<_From, _To, true>
938 typedef typename remove_cv<
typename remove_reference<
939 _From>::type>::type __src_t;
940 typedef typename remove_cv<
typename remove_reference<
941 _To>::type>::type __dst_t;
942 typedef __and_<__not_<is_function<__src_t>>,
943 __or_<is_same<__src_t, __dst_t>,
944 is_base_of<__dst_t, __src_t>>> type;
945 static constexpr
bool value = type::value;
948 template<
typename _From,
typename _To>
949 struct __is_lvalue_to_rvalue_ref<_From, _To, false>
959 template<
typename _Tp,
typename _Arg>
960 struct __is_direct_constructible_ref_cast
961 :
public __and_<__is_static_castable<_Arg, _Tp>,
962 __not_<__or_<__is_base_to_derived_ref<_Arg, _Tp>,
963 __is_lvalue_to_rvalue_ref<_Arg, _Tp>
967 template<
typename _Tp,
typename _Arg>
968 struct __is_direct_constructible_new
969 :
public conditional<is_reference<_Tp>::value,
970 __is_direct_constructible_ref_cast<_Tp, _Arg>,
971 __is_direct_constructible_new_safe<_Tp, _Arg>
975 template<
typename _Tp,
typename _Arg>
976 struct __is_direct_constructible
977 :
public __is_direct_constructible_new<_Tp, _Arg>::type
985 struct __do_is_nary_constructible_impl
987 template<
typename _Tp,
typename... _Args,
typename
988 = decltype(_Tp(declval<_Args>()...))>
991 template<
typename,
typename...>
995 template<
typename _Tp,
typename... _Args>
996 struct __is_nary_constructible_impl
997 :
public __do_is_nary_constructible_impl
999 typedef decltype(__test<_Tp, _Args...>(0)) type;
1002 template<typename _Tp, typename... _Args>
1003 struct __is_nary_constructible
1004 : public __is_nary_constructible_impl<_Tp, _Args...>::type
1006 static_assert(
sizeof...(_Args) > 1,
1007 "Only useful for > 1 arguments");
1010 template<
typename _Tp,
typename... _Args>
1011 struct __is_constructible_impl
1012 :
public __is_nary_constructible<_Tp, _Args...>
1015 template<
typename _Tp,
typename _Arg>
1016 struct __is_constructible_impl<_Tp, _Arg>
1017 :
public __is_direct_constructible<_Tp, _Arg>
1020 template<
typename _Tp>
1021 struct __is_constructible_impl<_Tp>
1022 :
public is_default_constructible<_Tp>
1026 template<
typename _Tp,
typename... _Args>
1027 struct is_constructible
1028 :
public __is_constructible_impl<_Tp, _Args...>::type
1031 template<typename _Tp, bool = __is_referenceable<_Tp>::value>
1032 struct __is_copy_constructible_impl;
1034 template<
typename _Tp>
1035 struct __is_copy_constructible_impl<_Tp, false>
1038 template<
typename _Tp>
1039 struct __is_copy_constructible_impl<_Tp, true>
1040 :
public is_constructible<_Tp, const _Tp&>
1044 template<
typename _Tp>
1045 struct is_copy_constructible
1046 :
public __is_copy_constructible_impl<_Tp>
1049 template<typename _Tp, bool = __is_referenceable<_Tp>::value>
1050 struct __is_move_constructible_impl;
1052 template<
typename _Tp>
1053 struct __is_move_constructible_impl<_Tp, false>
1056 template<
typename _Tp>
1057 struct __is_move_constructible_impl<_Tp, true>
1058 :
public is_constructible<_Tp, _Tp&&>
1062 template<
typename _Tp>
1063 struct is_move_constructible
1064 :
public __is_move_constructible_impl<_Tp>
1067 template<
typename _Tp>
1068 struct __is_nt_default_constructible_atom
1069 :
public integral_constant<bool, noexcept(_Tp())>
1072 template<typename _Tp, bool = is_array<_Tp>::value>
1073 struct __is_nt_default_constructible_impl;
1075 template<
typename _Tp>
1076 struct __is_nt_default_constructible_impl<_Tp, true>
1077 :
public __and_<__is_array_known_bounds<_Tp>,
1078 __is_nt_default_constructible_atom<typename
1079 remove_all_extents<_Tp>::type>>::type
1082 template<
typename _Tp>
1083 struct __is_nt_default_constructible_impl<_Tp, false>
1084 :
public __is_nt_default_constructible_atom<_Tp>
1088 template<
typename _Tp>
1089 struct is_nothrow_default_constructible
1090 :
public __and_<is_default_constructible<_Tp>,
1091 __is_nt_default_constructible_impl<_Tp>>::type
1094 template<
typename _Tp,
typename... _Args>
1095 struct __is_nt_constructible_impl
1096 :
public integral_constant<bool, noexcept(_Tp(declval<_Args>()...))>
1099 template<
typename _Tp,
typename _Arg>
1100 struct __is_nt_constructible_impl<_Tp, _Arg>
1101 :
public integral_constant<bool,
1102 noexcept(static_cast<_Tp>(declval<_Arg>()))>
1105 template<
typename _Tp>
1106 struct __is_nt_constructible_impl<_Tp>
1107 :
public is_nothrow_default_constructible<_Tp>
1111 template<
typename _Tp,
typename... _Args>
1112 struct is_nothrow_constructible
1113 :
public __and_<is_constructible<_Tp, _Args...>,
1114 __is_nt_constructible_impl<_Tp, _Args...>>::type
1117 template<typename _Tp, bool = __is_referenceable<_Tp>::value>
1118 struct __is_nothrow_copy_constructible_impl;
1120 template<
typename _Tp>
1121 struct __is_nothrow_copy_constructible_impl<_Tp, false>
1124 template<
typename _Tp>
1125 struct __is_nothrow_copy_constructible_impl<_Tp, true>
1126 :
public is_nothrow_constructible<_Tp, const _Tp&>
1130 template<
typename _Tp>
1131 struct is_nothrow_copy_constructible
1132 :
public __is_nothrow_copy_constructible_impl<_Tp>
1135 template<typename _Tp, bool = __is_referenceable<_Tp>::value>
1136 struct __is_nothrow_move_constructible_impl;
1138 template<
typename _Tp>
1139 struct __is_nothrow_move_constructible_impl<_Tp, false>
1142 template<
typename _Tp>
1143 struct __is_nothrow_move_constructible_impl<_Tp, true>
1144 :
public is_nothrow_constructible<_Tp, _Tp&&>
1148 template<
typename _Tp>
1149 struct is_nothrow_move_constructible
1150 :
public __is_nothrow_move_constructible_impl<_Tp>
1153 template<
typename _Tp,
typename _Up>
1154 class __is_assignable_helper
1156 template<
typename _Tp1,
typename _Up1,
1157 typename = decltype(declval<_Tp1>() = declval<_Up1>())>
1161 template<
typename,
typename>
1166 typedef decltype(__test<_Tp, _Up>(0)) type;
1170 template<typename _Tp, typename _Up>
1171 struct is_assignable
1172 : public __is_assignable_helper<_Tp, _Up>::type
1175 template<typename _Tp, bool = __is_referenceable<_Tp>::value>
1176 struct __is_copy_assignable_impl;
1178 template<
typename _Tp>
1179 struct __is_copy_assignable_impl<_Tp, false>
1182 template<
typename _Tp>
1183 struct __is_copy_assignable_impl<_Tp, true>
1184 :
public is_assignable<_Tp&, const _Tp&>
1188 template<
typename _Tp>
1189 struct is_copy_assignable
1190 :
public __is_copy_assignable_impl<_Tp>
1193 template<typename _Tp, bool = __is_referenceable<_Tp>::value>
1194 struct __is_move_assignable_impl;
1196 template<
typename _Tp>
1197 struct __is_move_assignable_impl<_Tp, false>
1200 template<
typename _Tp>
1201 struct __is_move_assignable_impl<_Tp, true>
1202 :
public is_assignable<_Tp&, _Tp&&>
1206 template<
typename _Tp>
1207 struct is_move_assignable
1208 :
public __is_move_assignable_impl<_Tp>
1211 template<
typename _Tp,
typename _Up>
1212 struct __is_nt_assignable_impl
1213 :
public integral_constant<bool, noexcept(declval<_Tp>() = declval<_Up>())>
1217 template<
typename _Tp,
typename _Up>
1218 struct is_nothrow_assignable
1219 :
public __and_<is_assignable<_Tp, _Up>,
1220 __is_nt_assignable_impl<_Tp, _Up>>::type
1223 template<typename _Tp, bool = __is_referenceable<_Tp>::value>
1224 struct __is_nt_copy_assignable_impl;
1226 template<
typename _Tp>
1227 struct __is_nt_copy_assignable_impl<_Tp, false>
1230 template<
typename _Tp>
1231 struct __is_nt_copy_assignable_impl<_Tp, true>
1232 :
public is_nothrow_assignable<_Tp&, const _Tp&>
1236 template<
typename _Tp>
1237 struct is_nothrow_copy_assignable
1238 :
public __is_nt_copy_assignable_impl<_Tp>
1241 template<typename _Tp, bool = __is_referenceable<_Tp>::value>
1242 struct __is_nt_move_assignable_impl;
1244 template<
typename _Tp>
1245 struct __is_nt_move_assignable_impl<_Tp, false>
1248 template<
typename _Tp>
1249 struct __is_nt_move_assignable_impl<_Tp, true>
1250 :
public is_nothrow_assignable<_Tp&, _Tp&&>
1254 template<
typename _Tp>
1255 struct is_nothrow_move_assignable
1256 :
public __is_nt_move_assignable_impl<_Tp>
1274 template<
typename _Tp>
1275 struct is_trivially_destructible
1276 :
public __and_<is_destructible<_Tp>, integral_constant<bool,
1277 __has_trivial_destructor(_Tp)>>::type
1281 template<
typename _Tp>
1282 struct has_trivial_default_constructor
1283 :
public integral_constant<bool, __has_trivial_constructor(_Tp)>
1287 template<
typename _Tp>
1288 struct has_trivial_copy_constructor
1289 :
public integral_constant<bool, __has_trivial_copy(_Tp)>
1293 template<
typename _Tp>
1294 struct has_trivial_copy_assign
1295 :
public integral_constant<bool, __has_trivial_assign(_Tp)>
1299 template<
typename _Tp>
1300 struct has_virtual_destructor
1301 :
public integral_constant<bool, __has_virtual_destructor(_Tp)>
1308 template<
typename _Tp>
1310 :
public integral_constant<std::size_t, __alignof__(_Tp)> { };
1315 :
public integral_constant<std::size_t, 0> { };
1317 template<
typename _Tp, std::
size_t _Size>
1318 struct rank<_Tp[_Size]>
1319 :
public integral_constant<std::size_t, 1 + rank<_Tp>::value> { };
1321 template<
typename _Tp>
1323 :
public integral_constant<std::size_t, 1 + rank<_Tp>::value> { };
1326 template<
typename,
unsigned _U
int>
1328 :
public integral_constant<std::size_t, 0> { };
1330 template<
typename _Tp,
unsigned _U
int, std::
size_t _Size>
1331 struct extent<_Tp[_Size], _Uint>
1332 :
public integral_constant<std::size_t,
1333 _Uint == 0 ? _Size : extent<_Tp,
1337 template<
typename _Tp,
unsigned _U
int>
1338 struct extent<_Tp[], _Uint>
1339 :
public integral_constant<std::size_t,
1340 _Uint == 0 ? 0 : extent<_Tp,
1348 template<
typename,
typename>
1352 template<
typename _Tp>
1353 struct is_same<_Tp, _Tp>
1357 template<
typename _Base,
typename _Derived>
1359 :
public integral_constant<bool, __is_base_of(_Base, _Derived)>
1362 template<
typename _From,
typename _To,
1363 bool = __or_<is_void<_From>, is_function<_To>,
1364 is_array<_To>>::value>
1365 struct __is_convertible_helper
1366 {
typedef typename is_void<_To>::type type; };
1368 template<
typename _From,
typename _To>
1369 class __is_convertible_helper<_From, _To, false>
1371 template<
typename _To1>
1372 static void __test_aux(_To1);
1374 template<
typename _From1,
typename _To1,
1375 typename = decltype(__test_aux<_To1>(std::declval<_From1>()))>
1379 template<
typename,
typename>
1384 typedef decltype(__test<_From, _To>(0)) type;
1389 template<typename _From, typename _To>
1390 struct is_convertible
1391 : public __is_convertible_helper<_From, _To>::type
1398 template<
typename _Tp>
1400 {
typedef _Tp type; };
1402 template<
typename _Tp>
1403 struct remove_const<_Tp const>
1404 {
typedef _Tp type; };
1407 template<
typename _Tp>
1408 struct remove_volatile
1409 {
typedef _Tp type; };
1411 template<
typename _Tp>
1412 struct remove_volatile<_Tp volatile>
1413 {
typedef _Tp type; };
1416 template<
typename _Tp>
1420 remove_const<typename remove_volatile<_Tp>::type>::type type;
1424 template<
typename _Tp>
1426 {
typedef _Tp
const type; };
1429 template<
typename _Tp>
1431 {
typedef _Tp
volatile type; };
1434 template<
typename _Tp>
1438 add_const<typename add_volatile<_Tp>::type>::type type;
1441 #if __cplusplus > 201103L
1443 template<
typename _Tp>
1444 using remove_const_t =
typename remove_const<_Tp>::type;
1447 template<
typename _Tp>
1448 using remove_volatile_t =
typename remove_volatile<_Tp>::type;
1451 template<
typename _Tp>
1452 using remove_cv_t =
typename remove_cv<_Tp>::type;
1455 template<
typename _Tp>
1456 using add_const_t =
typename add_const<_Tp>::type;
1459 template<
typename _Tp>
1460 using add_volatile_t =
typename add_volatile<_Tp>::type;
1463 template<
typename _Tp>
1464 using add_cv_t =
typename add_cv<_Tp>::type;
1470 template<
typename _Tp>
1471 struct remove_reference
1472 {
typedef _Tp type; };
1474 template<
typename _Tp>
1475 struct remove_reference<_Tp&>
1476 {
typedef _Tp type; };
1478 template<
typename _Tp>
1479 struct remove_reference<_Tp&&>
1480 {
typedef _Tp type; };
1482 template<typename _Tp, bool = __is_referenceable<_Tp>::value>
1483 struct __add_lvalue_reference_helper
1484 {
typedef _Tp type; };
1486 template<
typename _Tp>
1487 struct __add_lvalue_reference_helper<_Tp, true>
1488 {
typedef _Tp& type; };
1491 template<
typename _Tp>
1492 struct add_lvalue_reference
1493 :
public __add_lvalue_reference_helper<_Tp>
1496 template<typename _Tp, bool = __is_referenceable<_Tp>::value>
1497 struct __add_rvalue_reference_helper
1498 {
typedef _Tp type; };
1500 template<
typename _Tp>
1501 struct __add_rvalue_reference_helper<_Tp, true>
1502 {
typedef _Tp&& type; };
1505 template<
typename _Tp>
1506 struct add_rvalue_reference
1507 :
public __add_rvalue_reference_helper<_Tp>
1510 #if __cplusplus > 201103L
1512 template<
typename _Tp>
1513 using remove_reference_t =
typename remove_reference<_Tp>::type;
1516 template<
typename _Tp>
1517 using add_lvalue_reference_t =
typename add_lvalue_reference<_Tp>::type;
1520 template<
typename _Tp>
1521 using add_rvalue_reference_t =
typename add_rvalue_reference<_Tp>::type;
1527 template<
typename _Unqualified,
bool _IsConst,
bool _IsVol>
1528 struct __cv_selector;
1530 template<
typename _Unqualified>
1531 struct __cv_selector<_Unqualified, false, false>
1532 {
typedef _Unqualified __type; };
1534 template<
typename _Unqualified>
1535 struct __cv_selector<_Unqualified, false, true>
1536 {
typedef volatile _Unqualified __type; };
1538 template<
typename _Unqualified>
1539 struct __cv_selector<_Unqualified, true, false>
1540 {
typedef const _Unqualified __type; };
1542 template<
typename _Unqualified>
1543 struct __cv_selector<_Unqualified, true, true>
1544 {
typedef const volatile _Unqualified __type; };
1546 template<
typename _Qualified,
typename _Unqualified,
1547 bool _IsConst = is_const<_Qualified>::value,
1548 bool _IsVol = is_volatile<_Qualified>::value>
1549 class __match_cv_qualifiers
1551 typedef __cv_selector<_Unqualified, _IsConst, _IsVol> __match;
1554 typedef typename __match::__type __type;
1558 template<
typename _Tp>
1559 struct __make_unsigned
1560 {
typedef _Tp __type; };
1563 struct __make_unsigned<char>
1564 {
typedef unsigned char __type; };
1567 struct __make_unsigned<signed char>
1568 {
typedef unsigned char __type; };
1571 struct __make_unsigned<short>
1572 {
typedef unsigned short __type; };
1575 struct __make_unsigned<int>
1576 {
typedef unsigned int __type; };
1579 struct __make_unsigned<long>
1580 {
typedef unsigned long __type; };
1583 struct __make_unsigned<long long>
1584 {
typedef unsigned long long __type; };
1586 #if !defined(__STRICT_ANSI__) && defined(_GLIBCXX_USE_INT128)
1588 struct __make_unsigned<__int128>
1589 {
typedef unsigned __int128 __type; };
1593 template<
typename _Tp,
1594 bool _IsInt = is_integral<_Tp>::value,
1595 bool _IsEnum = is_enum<_Tp>::value>
1596 class __make_unsigned_selector;
1598 template<
typename _Tp>
1599 class __make_unsigned_selector<_Tp, true, false>
1601 typedef __make_unsigned<typename remove_cv<_Tp>::type> __unsignedt;
1602 typedef typename __unsignedt::__type __unsigned_type;
1603 typedef __match_cv_qualifiers<_Tp, __unsigned_type> __cv_unsigned;
1606 typedef typename __cv_unsigned::__type __type;
1609 template<
typename _Tp>
1610 class __make_unsigned_selector<_Tp, false, true>
1613 typedef unsigned char __smallest;
1614 static const bool __b0 =
sizeof(_Tp) <=
sizeof(__smallest);
1615 static const bool __b1 =
sizeof(_Tp) <=
sizeof(
unsigned short);
1616 static const bool __b2 =
sizeof(_Tp) <=
sizeof(
unsigned int);
1617 typedef conditional<__b2, unsigned int, unsigned long> __cond2;
1618 typedef typename __cond2::type __cond2_type;
1619 typedef conditional<__b1, unsigned short, __cond2_type> __cond1;
1620 typedef typename __cond1::type __cond1_type;
1623 typedef typename conditional<__b0, __smallest, __cond1_type>::type __type;
1630 template<
typename _Tp>
1631 struct make_unsigned
1632 {
typedef typename __make_unsigned_selector<_Tp>::__type type; };
1636 struct make_unsigned<bool>;
1640 template<
typename _Tp>
1641 struct __make_signed
1642 {
typedef _Tp __type; };
1645 struct __make_signed<char>
1646 {
typedef signed char __type; };
1649 struct __make_signed<unsigned char>
1650 {
typedef signed char __type; };
1653 struct __make_signed<unsigned short>
1654 {
typedef signed short __type; };
1657 struct __make_signed<unsigned int>
1658 {
typedef signed int __type; };
1661 struct __make_signed<unsigned long>
1662 {
typedef signed long __type; };
1665 struct __make_signed<unsigned long long>
1666 {
typedef signed long long __type; };
1668 #if !defined(__STRICT_ANSI__) && defined(_GLIBCXX_USE_INT128)
1670 struct __make_signed<unsigned __int128>
1671 {
typedef __int128 __type; };
1675 template<
typename _Tp,
1676 bool _IsInt = is_integral<_Tp>::value,
1677 bool _IsEnum = is_enum<_Tp>::value>
1678 class __make_signed_selector;
1680 template<
typename _Tp>
1681 class __make_signed_selector<_Tp, true, false>
1683 typedef __make_signed<typename remove_cv<_Tp>::type> __signedt;
1684 typedef typename __signedt::__type __signed_type;
1685 typedef __match_cv_qualifiers<_Tp, __signed_type> __cv_signed;
1688 typedef typename __cv_signed::__type __type;
1691 template<
typename _Tp>
1692 class __make_signed_selector<_Tp, false, true>
1695 typedef signed char __smallest;
1696 static const bool __b0 =
sizeof(_Tp) <=
sizeof(__smallest);
1697 static const bool __b1 =
sizeof(_Tp) <=
sizeof(
signed short);
1698 static const bool __b2 =
sizeof(_Tp) <=
sizeof(
signed int);
1699 typedef conditional<__b2, signed int, signed long> __cond2;
1700 typedef typename __cond2::type __cond2_type;
1701 typedef conditional<__b1, signed short, __cond2_type> __cond1;
1702 typedef typename __cond1::type __cond1_type;
1705 typedef typename conditional<__b0, __smallest, __cond1_type>::type __type;
1712 template<
typename _Tp>
1714 {
typedef typename __make_signed_selector<_Tp>::__type type; };
1718 struct make_signed<bool>;
1720 #if __cplusplus > 201103L
1722 template<
typename _Tp>
1723 using make_signed_t =
typename make_signed<_Tp>::type;
1726 template<
typename _Tp>
1727 using make_unsigned_t =
typename make_unsigned<_Tp>::type;
1733 template<
typename _Tp>
1734 struct remove_extent
1735 {
typedef _Tp type; };
1737 template<
typename _Tp, std::
size_t _Size>
1738 struct remove_extent<_Tp[_Size]>
1739 {
typedef _Tp type; };
1741 template<
typename _Tp>
1742 struct remove_extent<_Tp[]>
1743 {
typedef _Tp type; };
1746 template<
typename _Tp>
1747 struct remove_all_extents
1748 {
typedef _Tp type; };
1750 template<
typename _Tp, std::
size_t _Size>
1751 struct remove_all_extents<_Tp[_Size]>
1752 {
typedef typename remove_all_extents<_Tp>::type type; };
1754 template<
typename _Tp>
1755 struct remove_all_extents<_Tp[]>
1756 {
typedef typename remove_all_extents<_Tp>::type type; };
1758 #if __cplusplus > 201103L
1760 template<
typename _Tp>
1761 using remove_extent_t =
typename remove_extent<_Tp>::type;
1764 template<
typename _Tp>
1765 using remove_all_extents_t =
typename remove_all_extents<_Tp>::type;
1770 template<
typename _Tp,
typename>
1771 struct __remove_pointer_helper
1772 {
typedef _Tp type; };
1774 template<
typename _Tp,
typename _Up>
1775 struct __remove_pointer_helper<_Tp, _Up*>
1776 {
typedef _Up type; };
1779 template<
typename _Tp>
1780 struct remove_pointer
1781 :
public __remove_pointer_helper<_Tp, typename remove_cv<_Tp>::type>
1785 template<
typename _Tp,
bool = __or_<__is_referenceable<_Tp>,
1786 is_
void<_Tp>>::value>
1787 struct __add_pointer_helper
1788 {
typedef _Tp type; };
1790 template<
typename _Tp>
1791 struct __add_pointer_helper<_Tp, true>
1792 {
typedef typename remove_reference<_Tp>::type* type; };
1794 template<
typename _Tp>
1796 :
public __add_pointer_helper<_Tp>
1799 #if __cplusplus > 201103L
1801 template<
typename _Tp>
1802 using remove_pointer_t =
typename remove_pointer<_Tp>::type;
1805 template<
typename _Tp>
1806 using add_pointer_t =
typename add_pointer<_Tp>::type;
1809 template<std::
size_t _Len>
1810 struct __aligned_storage_msa
1814 unsigned char __data[_Len];
1815 struct __attribute__((__aligned__)) { } __align;
1829 template<std::size_t _Len, std::size_t _Align =
1830 __alignof__(
typename __aligned_storage_msa<_Len>::__type)>
1831 struct aligned_storage
1835 unsigned char __data[_Len];
1836 struct __attribute__((__aligned__((_Align)))) { } __align;
1843 template<
typename _Up,
1844 bool _IsArray = is_array<_Up>::value,
1845 bool _IsFunction = is_function<_Up>::value>
1846 struct __decay_selector;
1849 template<
typename _Up>
1850 struct __decay_selector<_Up, false, false>
1851 {
typedef typename remove_cv<_Up>::type __type; };
1853 template<
typename _Up>
1854 struct __decay_selector<_Up, true, false>
1855 {
typedef typename remove_extent<_Up>::type* __type; };
1857 template<
typename _Up>
1858 struct __decay_selector<_Up, false, true>
1859 {
typedef typename add_pointer<_Up>::type __type; };
1862 template<
typename _Tp>
1865 typedef typename remove_reference<_Tp>::type __remove_type;
1868 typedef typename __decay_selector<__remove_type>::__type type;
1871 template<
typename _Tp>
1872 class reference_wrapper;
1875 template<
typename _Tp>
1876 struct __strip_reference_wrapper
1881 template<
typename _Tp>
1882 struct __strip_reference_wrapper<reference_wrapper<_Tp> >
1884 typedef _Tp& __type;
1887 template<
typename _Tp>
1888 struct __decay_and_strip
1890 typedef typename __strip_reference_wrapper<
1891 typename decay<_Tp>::type>::__type __type;
1897 template<
bool,
typename _Tp =
void>
1902 template<
typename _Tp>
1903 struct enable_if<true, _Tp>
1904 {
typedef _Tp type; };
1906 template<
typename... _Cond>
1907 using _Require =
typename enable_if<__and_<_Cond...>::value>::type;
1911 template<
bool _Cond,
typename _Iftrue,
typename _Iffalse>
1913 {
typedef _Iftrue type; };
1916 template<
typename _Iftrue,
typename _Iffalse>
1917 struct conditional<false, _Iftrue, _Iffalse>
1918 {
typedef _Iffalse type; };
1921 template<
typename... _Tp>
1926 struct __do_common_type_impl
1928 template<
typename _Tp,
typename _Up>
1929 static __success_type<
typename decay<decltype
1930 (
true ? std::declval<_Tp>()
1931 : std::declval<_Up>())>::type> _S_test(
int);
1933 template<
typename,
typename>
1934 static __failure_type _S_test(...);
1937 template<
typename _Tp,
typename _Up>
1938 struct __common_type_impl
1939 :
private __do_common_type_impl
1941 typedef decltype(_S_test<_Tp, _Up>(0)) type;
1944 struct __do_member_type_wrapper
1946 template<
typename _Tp>
1947 static __success_type<typename _Tp::type> _S_test(
int);
1950 static __failure_type _S_test(...);
1953 template<
typename _Tp>
1954 struct __member_type_wrapper
1955 :
private __do_member_type_wrapper
1957 typedef decltype(_S_test<_Tp>(0)) type;
1960 template<typename _CTp, typename... _Args>
1961 struct __expanded_common_type_wrapper
1963 typedef common_type<
typename _CTp::type, _Args...> type;
1966 template<
typename... _Args>
1967 struct __expanded_common_type_wrapper<__failure_type, _Args...>
1968 {
typedef __failure_type type; };
1970 template<
typename _Tp>
1971 struct common_type<_Tp>
1972 {
typedef typename decay<_Tp>::type type; };
1974 template<
typename _Tp,
typename _Up>
1975 struct common_type<_Tp, _Up>
1976 :
public __common_type_impl<_Tp, _Up>::type
1979 template<
typename _Tp,
typename _Up,
typename... _Vp>
1980 struct common_type<_Tp, _Up, _Vp...>
1981 :
public __expanded_common_type_wrapper<typename __member_type_wrapper<
1982 common_type<_Tp, _Up>>::type, _Vp...>::type
1986 template<
typename _Tp>
1987 struct underlying_type
1989 typedef __underlying_type(_Tp) type;
1992 template<typename _Tp>
1993 struct __declval_protector
1995 static const bool __stop =
false;
1996 static typename add_rvalue_reference<_Tp>::type __delegate();
1999 template<
typename _Tp>
2000 inline typename add_rvalue_reference<_Tp>::type
2003 static_assert(__declval_protector<_Tp>::__stop,
2004 "declval() must not be used!");
2005 return __declval_protector<_Tp>::__delegate();
2009 template<
typename _Signature>
2015 struct __result_of_memfun_ref_impl
2017 template<
typename _Fp,
typename _Tp1,
typename... _Args>
2018 static __success_type<decltype(
2019 (std::declval<_Tp1>().*std::declval<_Fp>())(std::declval<_Args>()...)
2022 template<
typename...>
2023 static __failure_type _S_test(...);
2026 template<
typename _MemPtr,
typename _Arg,
typename... _Args>
2027 struct __result_of_memfun_ref
2028 :
private __result_of_memfun_ref_impl
2030 typedef decltype(_S_test<_MemPtr, _Arg, _Args...>(0)) type;
2034 struct __result_of_memfun_deref_impl
2036 template<
typename _Fp,
typename _Tp1,
typename... _Args>
2037 static __success_type<decltype(
2038 ((*std::declval<_Tp1>()).*std::declval<_Fp>())(std::declval<_Args>()...)
2041 template<
typename...>
2042 static __failure_type _S_test(...);
2045 template<
typename _MemPtr,
typename _Arg,
typename... _Args>
2046 struct __result_of_memfun_deref
2047 :
private __result_of_memfun_deref_impl
2049 typedef decltype(_S_test<_MemPtr, _Arg, _Args...>(0)) type;
2053 struct __result_of_memobj_ref_impl
2055 template<
typename _Fp,
typename _Tp1>
2056 static __success_type<decltype(
2057 std::declval<_Tp1>().*std::declval<_Fp>()
2060 template<
typename,
typename>
2061 static __failure_type _S_test(...);
2064 template<
typename _MemPtr,
typename _Arg>
2065 struct __result_of_memobj_ref
2066 :
private __result_of_memobj_ref_impl
2068 typedef decltype(_S_test<_MemPtr, _Arg>(0)) type;
2072 struct __result_of_memobj_deref_impl
2074 template<
typename _Fp,
typename _Tp1>
2075 static __success_type<decltype(
2076 (*std::declval<_Tp1>()).*std::declval<_Fp>()
2079 template<
typename,
typename>
2080 static __failure_type _S_test(...);
2083 template<
typename _MemPtr,
typename _Arg>
2084 struct __result_of_memobj_deref
2085 :
private __result_of_memobj_deref_impl
2087 typedef decltype(_S_test<_MemPtr, _Arg>(0)) type;
2090 template<typename _MemPtr, typename _Arg>
2091 struct __result_of_memobj;
2093 template<typename _Res, typename _Class, typename _Arg>
2094 struct __result_of_memobj<_Res _Class::*, _Arg>
2096 typedef typename remove_cv<
typename remove_reference<
2097 _Arg>::type>::type _Argval;
2098 typedef _Res _Class::* _MemPtr;
2099 typedef typename conditional<__or_<is_same<_Argval, _Class>,
2100 is_base_of<_Class, _Argval>>::value,
2101 __result_of_memobj_ref<_MemPtr, _Arg>,
2102 __result_of_memobj_deref<_MemPtr, _Arg>
2106 template<
typename _MemPtr,
typename _Arg,
typename... _Args>
2107 struct __result_of_memfun;
2109 template<
typename _Res,
typename _Class,
typename _Arg,
typename... _Args>
2110 struct __result_of_memfun<_Res _Class::*, _Arg, _Args...>
2112 typedef typename remove_cv<
typename remove_reference<
2113 _Arg>::type>::type _Argval;
2114 typedef _Res _Class::* _MemPtr;
2115 typedef typename conditional<__or_<is_same<_Argval, _Class>,
2116 is_base_of<_Class, _Argval>>::value,
2117 __result_of_memfun_ref<_MemPtr, _Arg, _Args...>,
2118 __result_of_memfun_deref<_MemPtr, _Arg, _Args...>
2122 template<bool, bool,
typename _Functor,
typename... _ArgTypes>
2123 struct __result_of_impl
2125 typedef __failure_type type;
2128 template<
typename _MemPtr,
typename _Arg>
2129 struct __result_of_impl<true, false, _MemPtr, _Arg>
2130 :
public __result_of_memobj<typename decay<_MemPtr>::type, _Arg>
2133 template<
typename _MemPtr,
typename _Arg,
typename... _Args>
2134 struct __result_of_impl<false, true, _MemPtr, _Arg, _Args...>
2135 :
public __result_of_memfun<typename decay<_MemPtr>::type, _Arg, _Args...>
2139 struct __result_of_other_impl
2141 template<
typename _Fn,
typename... _Args>
2142 static __success_type<decltype(
2143 std::declval<_Fn>()(std::declval<_Args>()...)
2146 template<
typename...>
2147 static __failure_type _S_test(...);
2150 template<
typename _Functor,
typename... _ArgTypes>
2151 struct __result_of_impl<false, false, _Functor, _ArgTypes...>
2152 :
private __result_of_other_impl
2154 typedef decltype(_S_test<_Functor, _ArgTypes...>(0)) type;
2157 template<typename _Functor, typename... _ArgTypes>
2158 struct result_of<_Functor(_ArgTypes...)>
2159 : public __result_of_impl<
2160 is_member_object_pointer<
2161 typename remove_reference<_Functor>::type
2163 is_member_function_pointer<
2164 typename remove_reference<_Functor>::type
2166 _Functor, _ArgTypes...
2170 #if __cplusplus > 201103L
2172 template<
size_t _Len,
size_t _Align =
2173 __alignof__(
typename __aligned_storage_msa<_Len>::__type)>
2174 using aligned_storage_t =
typename aligned_storage<_Len, _Align>::type;
2177 template<
typename _Tp>
2178 using decay_t =
typename decay<_Tp>::type;
2181 template<
bool _Cond,
typename _Tp =
void>
2182 using enable_if_t =
typename enable_if<_Cond, _Tp>::type;
2185 template<
bool _Cond,
typename _Iftrue,
typename _Iffalse>
2186 using conditional_t =
typename conditional<_Cond, _Iftrue, _Iffalse>::type;
2189 template<
typename... _Tp>
2190 using common_type_t =
typename common_type<_Tp...>::type;
2193 template<
typename _Tp>
2194 using underlying_type_t =
typename underlying_type<_Tp>::type;
2197 template<
typename _Tp>
2198 using result_of_t =
typename result_of<_Tp>::type;
2207 #define _GLIBCXX_HAS_NESTED_TYPE(_NTYPE) \
2208 template<typename _Tp> \
2209 class __has_##_NTYPE##_helper \
2211 template<typename _Up> \
2215 template<typename _Up> \
2216 static true_type __test(_Wrap_type<typename _Up::_NTYPE>*); \
2218 template<typename _Up> \
2219 static false_type __test(...); \
2222 typedef decltype(__test<_Tp>(0)) type; \
2225 template<typename _Tp> \
2226 struct __has_##_NTYPE \
2227 : public __has_##_NTYPE##_helper \
2228 <typename remove_cv<_Tp>::type>::type \
2231 _GLIBCXX_END_NAMESPACE_VERSION
2236 #endif // _GLIBCXX_TYPE_TRAITS
is_member_function_pointer
__is_nullptr_t (extension).
integral_constant< bool, true > true_type
The type used as a compile-time boolean with true value.
is_null_pointer (LWG 2247).
integral_constant< bool, false > false_type
The type used as a compile-time boolean with false value.