1#ifndef NEFORCE_CORE_TYPEINFO_TYPE_TRAITS_HPP__
2#define NEFORCE_CORE_TYPEINFO_TYPE_TRAITS_HPP__
12NEFORCE_BEGIN_NAMESPACE__
35template <
typename T, T Value>
37 static constexpr T
value = Value;
72template <u
int32_t Value>
80template <u
int64_t Value>
91template <
typename... Types>
103template <
bool Test,
typename T =
void>
117template <
bool Test,
typename T =
void>
128template <
bool Test,
typename T1,
typename T2>
134template <
typename T1,
typename T2>
144template <
bool Test,
typename T1,
typename T2>
158#ifdef NEFORCE_STANDARD_14
174template <
typename T1,
typename T2>
182#ifdef NEFORCE_STANDARD_14
187template <
typename T1,
typename T2>
218template <
typename T,
typename... Types>
221#ifdef NEFORCE_STANDARD_17
222template <
typename T,
typename... Types>
225template <
typename T,
typename... Types>
229template <
typename T,
typename U>
232template <
typename T,
typename U,
typename... Types>
237#ifdef NEFORCE_STANDARD_14
242template <
typename T,
typename... Types>
250template <bool,
typename first,
typename...>
251struct __disjunction_aux {
254template <
typename Curr,
typename Next,
typename... Rest>
255struct __disjunction_aux<false, Curr, Next, Rest...> {
256 using type =
typename __disjunction_aux<static_cast<bool>(Next::value), Next, Rest...>::type;
268template <
typename... Args>
272template <
typename First,
typename... Rest>
273struct disjunction<First, Rest...> : inner::__disjunction_aux<static_cast<bool>(First::value), First, Rest...>
::type {};
276#ifdef NEFORCE_STANDARD_14
281template <
typename... Args>
289template <bool,
typename First,
typename...>
290struct __conjunction_aux {
293template <
typename Curr,
typename Next,
typename... Rest>
294struct __conjunction_aux<true, Curr, Next, Rest...> {
295 using type =
typename __conjunction_aux<static_cast<bool>(Next::value), Next, Rest...>::type;
307template <
typename... Args>
311template <
typename First,
typename... Rest>
312struct conjunction<First, Rest...> : inner::__conjunction_aux<static_cast<bool>(First::value), First, Rest...>
::type {};
315#ifdef NEFORCE_STANDARD_14
320template <
typename... Args>
397 template <
typename wrapper>
406 template <
typename wrapper>
414 template <
typename wrapper>
422 template <
typename wrapper>
423 using bind_cv_t =
const volatile wrapper;
440template <
typename From,
typename To>
459 template <
typename wrapper>
468 template <
typename wrapper>
476 template <
typename wrapper>
494template <
typename From,
typename To>
503template <
typename From,
typename To>
536template <
typename T,
size_t Idx>
566template <
typename T,
size_t Idx>
568 using type =
typename remove_all_extents<T>::type;
573 using type =
typename remove_all_extents<T>::type;
600 template <
typename wrapper>
609 template <
typename wrapper>
617 template <
typename wrapper>
625 template <
typename wrapper>
633 template <
typename wrapper>
651template <
typename From,
typename To>
667template <
typename Ret,
typename... Args>
669 using type = Ret(Args...);
672#define __NEFORCE_EXPAND_REM_FUNC_QULF(QUF) \
673 template <typename Ret, typename... Args> \
674 struct remove_function_qualifiers<Ret(Args...) QUF> { \
675 using type = Ret(Args...); \
680#ifdef NEFORCE_STANDARD_17
683#undef __NEFORCE_EXPAND_REM_FUNC_QULF
708struct __is_void_helper<void> :
true_type {};
720struct is_void : inner::__is_void_helper<remove_cv_t<T>>::type {};
722#ifdef NEFORCE_STANDARD_14
738template <
typename T,
typename Dummy =
void>
758#ifdef NEFORCE_STANDARD_14
773template <
typename T,
typename Dummy =
void>
800#ifdef NEFORCE_STANDARD_14
817#ifdef NEFORCE_STANDARD_20
820 char16_t, char32_t>::value> {
823#ifdef NEFORCE_STANDARD_14
841#ifdef NEFORCE_STANDARD_14
860:
bool_constant<is_any_of<remove_cvref_t<T>, signed char, short, int, long, long long, unsigned char, unsigned short,
861 unsigned int, unsigned long, unsigned long long>::value> {};
863#ifdef NEFORCE_STANDARD_14
883#ifdef NEFORCE_STANDARD_14
901#ifdef NEFORCE_STANDARD_14
921#ifdef NEFORCE_STANDARD_14
933template <typename T, bool = is_integral<T>::value>
934struct __check_sign_aux {
940struct __check_sign_aux<T, false> {
942 static constexpr bool is_unsigned =
false;
955#ifdef NEFORCE_STANDARD_14
972#ifdef NEFORCE_STANDARD_14
996 using type =
const T;
1003template <
typename T>
1013template <
typename T>
1019template <
typename T>
1028template <
typename T>
1030 using type =
volatile T;
1037template <
typename T>
1045template <
typename T>
1047 using type =
const volatile T;
1054template <
typename T>
1066template <
typename T,
typename Dummy =
void>
1073template <
typename T>
1085template <
typename T>
1087 using type =
typename add_reference<T>::lvalue;
1094template <
typename T>
1102template <
typename T>
1104 using type =
typename add_reference<T>::rvalue;
1111template <
typename T>
1121template <
typename T,
typename Dummy =
void>
1127template <
typename T>
1137template <
typename T>
1154template <
typename T>
1157template <typename T>
1166template <typename T>
1174template <typename T>
1192template <typename T>
1196template <
typename T,
size_t Idx>
1199template <
typename T>
1203#ifdef NEFORCE_STANDARD_14
1208template <
typename T>
1221template <
typename T, u
int32_t Idx = 0>
1225template <
typename T,
size_t N>
1228template <
typename T, u
int32_t Idx,
size_t N>
1231template <
typename T, u
int32_t Idx>
1235#ifdef NEFORCE_STANDARD_14
1240template <
typename T, u
int32_t Idx = 0>
1257template <
typename T>
1261template <
template <
typename,
typename...>
class T,
typename First,
typename... Rest>
1271template <
typename Tmp>
1280template <
typename... Types>
1284template <
typename First,
typename... Rest>
1294template <
typename... Types>
1306template <
typename T,
typename Dummy =
void>
1312template <
typename T>
1314 using type =
typename T::difference_type;
1322template <
typename T>
1332template <
typename NewFirst,
typename T>
1336template <
typename NewFirst,
template <
typename,
typename...>
class T,
typename First,
typename... Rest>
1338 using type = T<NewFirst, Rest...>;
1346template <
typename T,
typename U>
1359template <
typename T,
typename U,
typename Dummy =
void>
1365template <
typename T,
typename U>
1367 enable_if_t<
is_same<typename T::template rebind<U>, typename T::template rebind<U>>::value>> {
1368 using type =
typename T::template rebind<U>;
1376template <
typename T,
typename U>
1392template <
typename T>
1396template <
typename T,
size_t Idx>
1400#ifdef NEFORCE_STANDARD_14
1405template <
typename T>
1415template <
typename T>
1419template <
typename T>
1423#ifdef NEFORCE_STANDARD_14
1428template <
typename T>
1439template <
typename T>
1442#ifdef NEFORCE_STANDARD_14
1447template <
typename T>
1457template <
typename T>
1461template <
typename T>
1465#ifdef NEFORCE_STANDARD_14
1470template <
typename T>
1479template <
typename T>
1483template <
typename T>
1487#ifdef NEFORCE_STANDARD_14
1492template <
typename T>
1504template <
typename T>
1507#ifdef NEFORCE_STANDARD_14
1512template <
typename T>
1522template <
typename T>
1525#ifdef NEFORCE_STANDARD_14
1530template <
typename T>
1542template <
typename T>
1546template <
typename T>
1549template <
typename T>
1552template <
typename T>
1555template <
typename T>
1559#ifdef NEFORCE_STANDARD_14
1564template <
typename T>
1574template <
typename T>
1577#ifdef NEFORCE_STANDARD_14
1582template <
typename T>
1594template <
typename T>
1597#ifdef NEFORCE_STANDARD_14
1602template <
typename T>
1612template <
typename T>
1615#ifdef NEFORCE_STANDARD_14
1620template <
typename T>
1630template <
typename T>
1633#ifdef NEFORCE_STANDARD_14
1638template <
typename T>
1650template <
typename T>
1653#ifdef NEFORCE_STANDARD_14
1658template <
typename T>
1670template <
typename T>
1673#ifdef NEFORCE_STANDARD_14
1678template <
typename T>
1683template <
typename T,
typename =
void>
1686template <
typename T>
1689#ifdef NEFORCE_STANDARD_14
1690template <
typename T>
1700template <
typename T>
1704template <
typename T>
1708#ifdef NEFORCE_STANDARD_14
1713template <
typename T>
1723template <
typename T>
1727template <
typename T>
1731#ifdef NEFORCE_STANDARD_14
1736template <
typename T>
1741#ifdef NEFORCE_COMPILER_MSVC
1743# pragma warning(push)
1744# pragma warning(disable : 4180)
1755template <
typename T>
1757 !is_reference<remove_function_qualifiers_t<T>>::value> {};
1759#ifdef NEFORCE_STANDARD_14
1764template <
typename T>
1768#ifdef NEFORCE_COMPILER_MSVC
1769# pragma warning(pop)
1785template <
typename T>
1787:
bool_constant<!(is_void<T>::value || is_reference<T>::value || is_function<T>::value || is_const<T>::value) &&
1788 is_complete<T>::value> {};
1790#ifdef NEFORCE_STANDARD_14
1795template <
typename T>
1800#ifdef NEFORCE_COMPILER_MSVC
1801# pragma warning(push)
1802# pragma warning(disable : 4180)
1813template <
typename T>
1816#ifdef NEFORCE_STANDARD_14
1821template <
typename T>
1825#ifdef NEFORCE_COMPILER_MSVC
1826# pragma warning(pop)
1839template <
typename T>
1841:
bool_constant<(is_pointer<remove_cvref_t<T>>::value && is_character<remove_pointer_t<remove_cvref_t<T>>>::value) ||
1842 (is_bounded_array<remove_cvref_t<T>>::value &&
1843 is_character<remove_all_extents_t<remove_cvref_t<T>>>::value)> {};
1845#ifdef NEFORCE_STANDARD_14
1850template <
typename T>
1860template <
typename T>
1864#ifdef NEFORCE_COMPILER_CLANG
1865template <
typename T>
1868NEFORCE_BEGIN_INNER__
1870struct __is_member_function_pointer_aux :
false_type {};
1871template <
typename T,
typename C>
1872struct __is_member_function_pointer_aux<T C::*> :
is_function<T> {};
1875template <
typename T>
1880#ifdef NEFORCE_STANDARD_14
1885template <
typename T>
1895template <
typename T>
1899#ifdef NEFORCE_COMPILER_CLANG
1900template <
typename T>
1903template <
typename T>
1905template <
typename T,
typename C>
1910#ifdef NEFORCE_STANDARD_14
1915template <
typename T>
1925template <
typename T>
1929#ifdef NEFORCE_COMPILER_CLANG
1930template <
typename T>
1933template <
typename T>
1938#ifdef NEFORCE_STANDARD_14
1943template <
typename T>
1960template <
typename T>
1963 disjunction<is_arithmetic<T>, is_enum<T>, is_pointer<T>, is_member_pointer<T>, is_null_pointer<T>>::value> {};
1965#ifdef NEFORCE_STANDARD_14
1970template <
typename T>
1985template <
typename T>
1988#ifdef NEFORCE_STANDARD_14
1993template <
typename T>
2005template <
typename T>
2008#ifdef NEFORCE_STANDARD_14
2013template <
typename T>
2025template <
typename T>
2028#ifdef NEFORCE_STANDARD_14
2033template <
typename T>
2045template <
typename T>
2048#ifdef NEFORCE_STANDARD_14
2053template <
typename T>
2059NEFORCE_BEGIN_INNER__
2060template <typename T, bool = is_enum<T>::value>
2061struct __underlying_type_aux {
2062 using type = __underlying_type(T);
2064template <
typename T>
2065struct __underlying_type_aux<T, false> {};
2076template <
typename T>
2083template <
typename T>
2098template <
typename T>
2101#ifdef NEFORCE_STANDARD_14
2106template <
typename T>
2118template <
typename T>
2121#ifdef NEFORCE_STANDARD_14
2126template <
typename T>
2143template <
typename T>
2146#ifdef NEFORCE_STANDARD_14
2151template <
typename T>
2168template <
typename T>
2172#ifdef NEFORCE_COMPILER_MSVC
2173template <
typename T>
2176template <
typename T>
2181#ifdef NEFORCE_STANDARD_14
2186template <
typename T>
2191#ifdef NEFORCE_COMPILER_MSVC
2202template <
typename T1,
typename T2>
2209# ifdef NEFORCE_STANDARD_14
2210template <
typename T1,
typename T2>
2223template <
typename Base,
typename Derived>
2226# ifdef NEFORCE_STANDARD_14
2231template <
typename Base,
typename Derived>
2244template <
typename Base,
typename Derived>
2247#ifdef NEFORCE_STANDARD_14
2252template <
typename Base,
typename Derived>
2257#ifdef NEFORCE_STANDARD_20
2267template <
typename T,
typename Mem>
2269 return __builtin_is_pointer_interconvertible_with_class(mp);
2284template <
typename S1,
typename S2,
typename M1,
typename M2>
2286 return __builtin_is_corresponding_member(m1, m2);
2308template <
typename T>
2311#ifdef NEFORCE_STANDARD_14
2316template <
typename T>
2328template <
typename T>
2331#ifdef NEFORCE_STANDARD_14
2336template <
typename T>
2346template <
typename T>
2349#ifdef NEFORCE_STANDARD_14
2354template <
typename T>
2365template <
typename T,
typename... Args>
2368#ifdef NEFORCE_STANDARD_14
2373template <
typename T,
typename... Args>
2383template <
typename T>
2386#ifdef NEFORCE_STANDARD_14
2391template <
typename T>
2401template <
typename T>
2404#ifdef NEFORCE_STANDARD_14
2409template <
typename T>
2415NEFORCE_BEGIN_INNER__
2416template <
typename T>
2417void __implicitly_default_construct_aux(
const T&)
noexcept;
2429template <
typename T,
typename Dummy =
void>
2433template <
typename T>
2438#ifdef NEFORCE_STANDARD_14
2443template <
typename T>
2453template <
typename T>
2456#ifdef NEFORCE_STANDARD_14
2461template <
typename T>
2472template <
typename To,
typename From>
2475#ifdef NEFORCE_STANDARD_14
2480template <
typename To,
typename From>
2492template <
typename T>
2494:
bool_constant<is_assignable<add_lvalue_reference_t<T>, add_lvalue_reference_t<const T>>::value> {};
2496#ifdef NEFORCE_STANDARD_14
2501template <
typename T>
2513template <
typename T>
2516#ifdef NEFORCE_STANDARD_14
2521template <
typename T>
2536template <
typename T>
2540#ifdef NEFORCE_COMPILER_MSVC
2541template <
typename T>
2544NEFORCE_BEGIN_INNER__
2545template <
typename T>
2546struct __destructible_aux {
2548 template <typename T1, typename = decltype(declval<T1&>().~T1())>
2554 using type =
decltype(__test<T>(0));
2557template <
typename T,
bool = disjunction<is_
void<T>, is_unbounded_array<T>, is_function<T>>::value,
2558 bool = disjunction<is_reference<T>, is_scalar<T>>::value>
2559struct __is_destructible_dispatch;
2561template <
typename T>
2562struct __is_destructible_dispatch<T, false, false> : __destructible_aux<remove_all_extents_t<T>>::type {};
2564template <
typename T>
2565struct __is_destructible_dispatch<T, true, false> :
false_type {};
2567template <
typename T>
2568struct __is_destructible_dispatch<T, false, true> :
true_type {};
2572template <
typename T>
2573struct is_destructible : inner::__is_destructible_dispatch<T>::type {};
2577#ifdef NEFORCE_STANDARD_14
2582template <
typename T>
2595template <
typename T,
typename... Args>
2598#ifdef NEFORCE_STANDARD_14
2603template <
typename T,
typename... Args>
2613template <
typename T>
2615:
bool_constant<is_trivially_constructible<T, add_lvalue_reference_t<const T>>::value> {};
2617#ifdef NEFORCE_STANDARD_14
2622template <
typename T>
2632template <
typename T>
2635#ifdef NEFORCE_STANDARD_14
2640template <
typename T>
2650template <
typename T>
2653#ifdef NEFORCE_STANDARD_14
2658template <
typename T>
2669template <
typename To,
typename From>
2672#ifdef NEFORCE_STANDARD_14
2677template <
typename To,
typename From>
2687template <
typename T>
2689:
bool_constant<is_trivially_assignable<add_lvalue_reference_t<T>, add_lvalue_reference_t<const T>>::value> {};
2691#ifdef NEFORCE_STANDARD_14
2696template <
typename T>
2706template <
typename T>
2709#ifdef NEFORCE_STANDARD_14
2714template <
typename T>
2726template <
typename T>
2728#if defined(NEFORCE_COMPILER_MSVC) || defined(NEFORCE_COMPILER_CLANG)
2736#ifdef NEFORCE_STANDARD_14
2741template <
typename T>
2752template <
typename T,
typename... Args>
2760template <
typename T>
2764#ifdef NEFORCE_COMPILER_MSVC
2765template <
typename T,
typename... Args>
2768NEFORCE_BEGIN_INNER__
2769template <typename T, bool = is_array<T>::value>
2770struct __is_nothrow_default_constructible_dispatch;
2772template <
typename T>
2773struct __is_nothrow_default_constructible_dispatch<T, true>
2774:
conjunction<is_bounded_array<T>, bool_constant<noexcept(remove_all_extents_t<T>())>> {};
2776template <
typename T>
2777struct __is_nothrow_default_constructible_dispatch<T, false> :
bool_constant<noexcept(T())> {};
2781template <
typename T>
2783:
conjunction<is_default_constructible<T>, inner::__is_nothrow_default_constructible_dispatch<T>> {};
2785NEFORCE_BEGIN_INNER__
2787template <
typename T,
typename... Args>
2788struct __is_nothrow_constructible_dispatch :
bool_constant<noexcept(T(_NEFORCE declval<Args>()...))> {};
2790template <
typename T>
2795template <
typename T,
typename... Args>
2797:
conjunction<is_constructible<T, Args...>, inner::__is_nothrow_constructible_dispatch<T, Args...>> {};
2801#ifdef NEFORCE_STANDARD_14
2806template <
typename T,
typename... Args>
2816template <
typename T>
2818:
bool_constant<is_nothrow_constructible<T, add_lvalue_reference_t<const T>>::value> {};
2820#ifdef NEFORCE_STANDARD_14
2825template <
typename T>
2831#ifdef NEFORCE_COMPILER_MSVC
2832template <
typename T>
2838#ifdef NEFORCE_STANDARD_14
2843template <
typename T>
2853template <
typename T>
2856#ifdef NEFORCE_STANDARD_14
2861template <
typename T>
2872template <
typename To,
typename From>
2876template <
typename To,
typename From>
2880#ifdef NEFORCE_STANDARD_14
2885template <
typename To,
typename From>
2895template <
typename T>
2897:
bool_constant<is_nothrow_assignable<add_lvalue_reference_t<T>, add_lvalue_reference_t<const T>>::value> {};
2899#ifdef NEFORCE_STANDARD_14
2904template <
typename T>
2914template <
typename T>
2917#ifdef NEFORCE_STANDARD_14
2922template <
typename T>
2927#ifndef NEFORCE_COMPILER_MSVC
2929NEFORCE_BEGIN_INNER__
2930template <
typename T>
2931struct __is_nothrow_destructible_aux {
2933 template <
typename T1>
2940 using type =
decltype(__test<T>(0));
2943template <
typename T,
bool = disjunction<is_
void<T>, is_unbounded_array<T>, is_function<T>>::value,
2944 bool = disjunction<is_reference<T>, is_scalar<T>>::value>
2945struct __is_nothrow_destructible_dispatch;
2947template <
typename T>
2948struct __is_nothrow_destructible_dispatch<T, false, false>
2949: __is_nothrow_destructible_aux<remove_all_extents_t<T>>::type {};
2951template <
typename T>
2952struct __is_nothrow_destructible_dispatch<T, true, false> :
false_type {};
2954template <
typename T>
2955struct __is_nothrow_destructible_dispatch<T, false, true> :
true_type {};
2966template <
typename T>
2970template <
typename T>
2972#ifdef NEFORCE_COMPILER_MSVC
2976 inner::__is_nothrow_destructible_dispatch<T>::type {
2981#ifdef NEFORCE_STANDARD_14
2986template <
typename T>
2999template <
typename T>
3002#ifdef NEFORCE_STANDARD_14
3007template <
typename T>
3027template <
typename T>
3029 return static_cast<T&&
>(x);
3041template <
typename T>
3044 return static_cast<T&&
>(x);
3055template <
typename T>
3068template <
typename T>
3072 return _NEFORCE
move(x);
3083template <
typename T>
3085 return __builtin_addressof(x);
3093template <
typename T>
3097template <
typename T,
typename U>
3098constexpr size_t offset_of(U T::* member) {
3099 return reinterpret_cast<size_t>(&(
reinterpret_cast<T
const volatile*
>(
nullptr)->*member));
3111#if !defined(NEFORCE_COMPILER_MSVC) && !defined(NEFORCE_COMPILER_CLANG)
3113NEFORCE_BEGIN_INNER__
3114template <
typename From,
typename To,
bool = disjunction_v<is_
void<From>, is_function<To>, is_array<To>>>
3115struct __is_convertible_helper {
3116 using type =
typename is_void<To>::type;
3119template <
typename From,
typename To>
3120struct __is_convertible_helper<From, To, false> {
3122 template <typename From1, typename To1, typename = decltype(_NEFORCE declvoid<To1>(_NEFORCE
declval<From1>()))>
3125 template <
typename,
typename>
3129 using type =
decltype(__test<From, To>(0));
3141template <
typename From,
typename To>
3143#if defined(NEFORCE_COMPILER_MSVC)
3146#elif defined(NEFORCE_COMPILER_CLANG)
3150 inner::__is_convertible_helper<From, To>::type {
3154#ifdef NEFORCE_STANDARD_14
3159template <
typename From,
typename To>
3163#if defined(NEFORCE_STANDARD_20) || defined(NEXUSFORCE_ENABLE_DOXYGEN)
3170template <
typename From,
typename To>
3183template <
typename ToElement,
typename FromElement>
3186#ifdef NEFORCE_STANDARD_14
3191template <
typename ToElement,
typename FromElement>
3204template <typename From, typename To, bool IsConvertible = is_convertible<From, To>::value,
3209template <
typename From,
typename To,
bool IsVo
id>
3212template <
typename From,
typename To>
3216#ifdef NEFORCE_STANDARD_14
3221template <
typename From,
typename To>
3233template <
typename Iterator,
typename Ptr,
bool IsPtr = is_po
inter<remove_cvref_t<Iterator>>::value>
3237template <
typename Iterator,
typename Ptr>
3239:
bool_constant<noexcept(_NEFORCE declcopy<Ptr>(_NEFORCE declval<Iterator>().operator->()))> {};
3242#ifdef NEFORCE_STANDARD_14
3247template <
typename Iterator,
typename Ptr>
3260NEFORCE_BEGIN_INNER__
3262struct __sign_byte_aux;
3265struct __sign_byte_aux<1> {
3267 using signed_t =
signed char;
3269 using unsigned_t =
unsigned char;
3272struct __sign_byte_aux<2> {
3274 using signed_t =
signed short;
3276 using unsigned_t =
unsigned short;
3279struct __sign_byte_aux<4> {
3280#ifdef NEFORCE_PLATFORM_WINDOWS
3281 template <
typename T>
3284 template <
typename T>
3289 using signed_t =
signed int;
3291 using unsigned_t =
unsigned int;
3295struct __sign_byte_aux<8> {
3296#ifdef NEFORCE_PLATFORM_WINDOWS
3298 using signed_t =
signed long long;
3300 using unsigned_t =
unsigned long long;
3302 template <
typename T>
3306 template <
typename T>
3308 unsigned long long>;
3311#if defined(NEFORCE_COMPILER_GNUC) && defined(__SIZEOF_INT128__)
3313struct __sign_byte_aux<16> {
3315 using signed_t =
signed __int128;
3317 using unsigned_t =
unsigned __int128;
3330template <
typename T>
3332 using type =
copy_cv_t<T,
typename inner::__sign_byte_aux<
sizeof(T)>::template signed_t<T>>;
3339template <
typename T>
3349template <
typename T>
3351 using type =
copy_cv_t<T,
typename inner::__sign_byte_aux<
sizeof(T)>::template unsigned_t<T>>;
3358template <
typename T>
3363NEFORCE_BEGIN_INNER__
3364template <
size_t Size,
bool IsSigned>
3365struct __make_integer_impl;
3367template <
size_t Size>
3368struct __make_integer_impl<Size, true> {
3369 using type =
typename __sign_byte_aux<Size>::template signed_t<int>;
3372template <
size_t Size>
3373struct __make_integer_impl<Size, false> {
3374 using type =
typename __sign_byte_aux<Size>::template unsigned_t<int>;
3385template <
size_t Size,
bool IsSigned = true>
3387 using type =
typename inner::__make_integer_impl<Size, IsSigned>::type;
3394template <
size_t Size,
bool IsSigned = true>
3403template <
size_t... Values>
3407template <
size_t Value>
3410template <
size_t First,
size_t Second,
size_t... Rest>
3411struct max_value<First, Second, Rest...> :
max_value<(First > Second ? First : Second), Rest...> {};
3414#ifdef NEFORCE_STANDARD_14
3415template <
size_t... Values>
3416NEFORCE_INLINE17
constexpr size_t max_value_v =
max_value<Values...>::value;
3432template <
typename T>
3435#ifdef NEFORCE_STANDARD_14
3440template <
typename T>
3451template <
size_t Len,
size_t Align = alignof(_NEFORCE max_align_t)>
3453 static_assert((Align & (Align - 1)) == 0,
"Alignment must be power of two");
3468template <
size_t Len,
size_t Align = alignof(_NEFORCE max_align_t)>
3480template <
size_t Len,
typename... Types>
3483 static constexpr size_t required_alignment =
max_value<
alignof(Types)...>::value;
3484 static constexpr size_t required_size =
max_value<
sizeof(Types)...>::value;
3485 static constexpr size_t storage_size = (Len > required_size) ? Len : required_size;
3487 static_assert((required_alignment & (required_alignment - 1)) == 0,
"Alignment must be power of two");
3503 struct alignas(alignment_value)
type {
3517 template <
typename T>
3527template <
size_t Len,
typename... Types>
3530#ifdef NEFORCE_STANDARD_14
3535template <
size_t Len,
typename... Types>
3557template <
typename T>
3561 using check_func_t =
3573template <
typename T>
3578NEFORCE_BEGIN_INNER__
3579template <
typename Default,
typename,
template <
typename...>
class,
typename...>
3582 using type = Default;
3584template <
typename Default,
template <
typename...>
class Op,
typename... Args>
3585struct __detector<Default,
void_t<Op<Args...>>, Op, Args...> {
3587 using type = Op<Args...>;
3599template <
typename Default,
template <
typename...>
class Op,
typename... Args>
3606template <
typename Default,
template <
typename...>
class Op,
typename... Args>
3621template <
typename T1,
typename T2>
3626NEFORCE_BEGIN_INNER__
3627template <
typename,
typename,
typename =
void>
3628struct __oper_decay_aux {};
3629template <
typename T1,
typename T2>
3641template <
typename... Types>
3648template <
typename... Types>
3655template <
typename T1>
3656struct common_type<T1> : common_type<T1, T1> {};
3658template <
typename T1,
typename T2>
3659struct common_type<T1, T2> : inner::__oper_decay_aux<T1, T2> {};
3661template <
typename T1,
typename T2,
typename... Rest>
3662struct common_type<T1, T2, Rest...> : common_type<common_type_t<T1, T2>, Rest...> {};
3666#ifdef NEFORCE_STANDARD_20
3673template <
typename... Types>
3680template <
typename... Types>
3688template <
typename T>
3689struct common_reference<T> {
3694NEFORCE_BEGIN_INNER__
3696template <
typename T1,
typename T2>
3697struct __common_reference_base_aux : common_type<T1, T2> {};
3699template <
typename T1,
typename T2>
3701struct __common_reference_base_aux<T1, T2> {
3705template <
typename,
typename,
template <
typename>
typename,
template <
typename>
typename>
3706struct __basic_common_reference {};
3708template <
typename T1>
3709struct __add_qualifier_aux {
3710 template <
typename T2>
3714template <
typename T1,
typename T2>
3715using qualifier_extract =
typename __basic_common_reference<remove_cvref_t<T1>,
remove_cvref_t<T2>,
3716 __add_qualifier_aux<T1>::template apply_t,
3717 __add_qualifier_aux<T2>::template apply_t>::type;
3719template <
typename T1,
typename T2>
3720struct __common_ref_qualify_aux : __common_reference_base_aux<T1, T2> {};
3722template <
typename T1,
typename T2>
3723 requires requires {
typename qualifier_extract<T1, T2>; }
3724struct __common_ref_qualify_aux<T1, T2> {
3725 using type = qualifier_extract<T1, T2>;
3728template <
typename T1,
typename T2>
3729struct __common_reference_ptr_aux : __common_ref_qualify_aux<T1, T2> {};
3731template <
typename T1,
typename T2>
3735template <
typename,
typename>
3736struct __common_reference_aux {};
3738template <
typename T1,
typename T2>
3739 requires requires {
typename __common_lvalue_aux<T1, T2>; }
3740struct __common_reference_aux<T1&, T2&> {
3741 using type = __common_lvalue_aux<T1, T2>;
3744template <
typename T1,
typename T2>
3746struct __common_reference_aux<T1&&, T2&> {
3747 using type = __common_lvalue_aux<const T1, T2>;
3750template <
typename T1,
typename T2>
3752struct __common_reference_aux<T1&, T2&&> {
3753 using type = __common_lvalue_aux<const T2, T1>;
3756template <
typename T1,
typename T2>
3759template <
typename T1,
typename T2>
3761struct __common_reference_aux<T1&&, T2&&> {
3762 using type = __common_rvalue_aux<T1, T2>;
3765template <
typename T1,
typename T2>
3766using __common_reference_aux_t =
typename __common_reference_aux<T1, T2>::type;
3768template <
typename T1,
typename T2>
3771struct __common_reference_ptr_aux<T1, T2> {
3772 using type = __common_reference_aux_t<T1, T2>;
3778template <
typename T1,
typename T2>
3779struct common_reference<T1, T2> : inner::__common_reference_ptr_aux<T1, T2> {};
3781template <
typename T1,
typename T2,
typename T3,
typename... Rest>
3782struct common_reference<T1, T2, T3, Rest...> {};
3784template <
typename T1,
typename T2,
typename T3,
typename... Rest>
3786struct common_reference<T1, T2, T3, Rest...> : common_reference<common_reference_t<T1, T2>, T3, Rest...> {};
3800template <
typename T,
template <
typename...>
class Template>
3804template <
template <
typename...>
class Template,
typename... Args>
3808#ifdef NEFORCE_STANDARD_17
3813template <
typename T,
template <
typename...>
class Template>
3822template <
typename T,
template <
typename...>
class Template>
3840struct is_nothrow_swappable;
3849template <
typename T>
3860template <
typename T,
size_t Size>
3877template <
typename T,
typename U = T>
3889template <
typename T1,
typename T2,
typename Dummy =
void>
3893template <
typename T1,
typename T2>
3907template <
typename T1,
typename T2>
3916template <
typename T>
3919#ifdef NEFORCE_STANDARD_14
3924template <
typename T>
3935template <
typename T1,
typename T2>
3937:
bool_constant<noexcept(_NEFORCE swap(_NEFORCE declval<T1>(), _NEFORCE declval<T2>())) &&
3938 noexcept(_NEFORCE swap(_NEFORCE declval<T2>(), _NEFORCE declval<T1>()))> {};
3947template <
typename T1,
typename T2>
3949:
bool_constant<conjunction<is_swappable_with<T1, T2>, is_nothrow_swappable_from<T1, T2>>::value> {};
3957template <
typename T>
3959:
bool_constant<is_nothrow_swappable_with<add_lvalue_reference_t<T>, add_lvalue_reference_t<T>>::value> {};
3961#ifdef NEFORCE_STANDARD_14
3966template <
typename T>
3981template <
typename T,
typename Dummy =
void>
3985template <
typename T>
4001template <
typename T>
4003:
bool_constant<conjunction<is_trivially_destructible<T>, is_trivially_move_constructible<T>,
4004 is_trivially_move_assignable<T>, negation<is_ADL_swappable<T>>>::value> {};
4006#ifdef NEFORCE_STANDARD_14
4011template <
typename T>
4017template <
typename T>
4020 T tmp = _NEFORCE
move(lhs);
4021 lhs = _NEFORCE
move(rhs);
4022 rhs = _NEFORCE
move(tmp);
4026template <
typename T,
size_t Size>
4027NEFORCE_CONSTEXPR14 enable_if_t<is_swappable<T>::value>
swap(T (&lhs)[Size],
4033 T* last1 = first1 + Size;
4035 for (; first1 != last1; ++first1, ++first2) {
4036 _NEFORCE
swap(*first1, *first2);
4041template <
typename T,
typename U>
4044 T old_val = _NEFORCE
move(val);
4059#ifdef NEFORCE_STANDARD_20
4069template <
typename T>
4071 typename T::first_type;
4072 typename T::second_type;
4089template <
typename Alloc,
typename Dummy =
void>
4093template <
typename Alloc>
4094struct is_allocator<Alloc,
void_t<typename Alloc::value_type, decltype(declval<Alloc&>().allocate(size_t{}))>>
4098#ifdef NEFORCE_STANDARD_14
4103template <
typename Alloc>
4109NEFORCE_BEGIN_INNER__
4110template <
typename T>
4111struct __has_valid_begin_end {
4113 template <
typename U>
4114 static auto __test(
int)
4118 template <
typename U>
4122 static constexpr bool value =
decltype(__test<T>(0))::value;
4133template <
typename Iterator>
4136 template <
typename U>
4139 template <
typename U>
4143 static constexpr bool value =
decltype(__test<Iterator>(0))::value;
4146#ifdef NEFORCE_STANDARD_14
4151template <
typename Iterator>
4161template <
typename Iterator>
4164 template <
typename U>
4167 template <
typename U>
4171 static constexpr bool value =
decltype(__test<Iterator>(0))::value;
4174#ifdef NEFORCE_STANDARD_14
4179template <
typename Iterator>
4193template <
typename Container>
4195 is_incrementible<decltype(declval<Container>().begin())>::value> {};
4197#ifdef NEFORCE_STANDARD_14
4202template <
typename T>
4208NEFORCE_BEGIN_INNER__
4209template <
typename T>
4210struct __has_first_and_second {
4212 template <
typename U>
4215 template <
typename U>
4219 static constexpr bool value =
decltype(__test<T>(0))::value;
4233template <
typename Map>
4236 inner::__has_first_and_second<decltype(*declval<decltype(declval<Map>().begin())>())>::value> {};
4238#ifdef NEFORCE_STANDARD_14
4243template <
typename Map>
4249NEFORCE_BEGIN_INNER__
4250template <
typename Alloc,
typename T,
typename... Args>
4251struct __has_construct_impl {
4253 template <typename Alloc1, typename = decltype(_NEFORCE declval<Alloc1*>()->construct(_NEFORCE
declval<T*>(),
4261 using type =
decltype(__test<Alloc>(0));
4273template <
typename Alloc,
typename T,
typename... Args>
4276#ifdef NEFORCE_STANDARD_14
4281template <
typename Alloc,
typename T,
typename... Args>
4287NEFORCE_BEGIN_INNER__
4288template <
typename T>
4289struct __has_base_impl {
4291 template <
typename U>
4294 template <
typename U>
4298 static constexpr bool value =
decltype(__test<T>(0))::value;
4308template <
typename T>
4311#ifdef NEFORCE_STANDARD_14
4316template <
typename T>
4338template <
typename T>
4344#define __NEFORCE_INITIALIZE_BASIC_FUNCTION(OPT) \
4346 NEFORCE_ALWAYS_INLINE constexpr OPT initialize() noexcept { \
4347 return static_cast<OPT>(0); \
4351#undef __NEFORCE_INITIALIZE_BASIC_FUNCTION
4357NEFORCE_END_NAMESPACE__
typename add_volatile< T >::type add_volatile_t
add_volatile的便捷别名
constexpr add_const_t< T > & as_const(T &val) noexcept
将值转换为const引用
typename add_pointer< T >::type add_pointer_t
add_pointer的便捷别名
typename add_const< T >::type add_const_t
add_const的便捷别名
typename add_cv< T >::type add_cv_t
add_cv的类型别名
typename add_reference< T >::lvalue add_lvalue_reference_t
add_lvalue_reference的便捷别名
typename add_reference< T >::rvalue add_rvalue_reference_t
add_rvalue_reference的便捷别名
constexpr size_t aligned_union_v
获取aligned_union的对齐要求值
typename aligned_union< Len, Types... >::type aligned_union_t
aligned_union的便捷别名
typename aligned_storage< Len, Align >::type aligned_storage_t
aligned_storage的便捷别名
constexpr size_t alignment_of_v
alignment_of的便捷变量模板
constexpr remove_reference_t< T > && move(T &&x) noexcept
无条件转换为右值引用
constexpr T && forward(remove_reference_t< T > &x) noexcept
完美转发左值
constexpr conditional_t<!is_nothrow_move_constructible< T >::value &&is_copy_constructible< T >::value, const T &, T && > move_if_noexcept(T &x) noexcept
在安全的情况下执行移动操作
constexpr T * addressof(T &x) noexcept
获取对象的地址
constexpr size_t rank_v
rank的便捷变量模板
constexpr size_t extent_v
extent的便捷变量模板
constexpr bool is_signed_v
is_signed的便捷变量模板
typename unpackage< T >::type unpackage_t
unpackage的便捷别名
constexpr bool is_character_v
is_character的便捷变量模板
constexpr bool is_integral_v
is_integral的便捷变量模板
constexpr bool is_boolean_v
is_boolean的便捷变量模板
constexpr bool is_void_v
is_void的便捷变量模板
constexpr bool is_floating_point_v
is_floating_point的便捷变量模板
constexpr bool is_packaged_v
is_packaged的便捷变量模板
unpackage_t< remove_cvref_t< T > > unpack_remove_cvref_t
同时解包并移除cv和引用限定符
constexpr bool is_arithmetic_v
is_arithmetic的便捷变量模板
constexpr bool is_unsigned_v
is_unsigned的便捷变量模板
typename package< T >::type package_t
package的便捷别名
constexpr bool is_standard_integral_v
is_standard_integral的便捷变量模板
constexpr bool is_unpackaged_v
is_unpackaged的便捷变量模板
constexpr bool is_scalar_v
is_scalar的便捷变量模板
constexpr bool is_base_of_v
is_base_of的便捷变量模板
constexpr bool is_lvalue_reference_v
is_lvalue_reference的便捷变量模板
constexpr bool is_const_v
is_const的便捷变量模板
constexpr bool is_abstract_v
is_abstract的便捷变量模板
typename underlying_type< T >::type underlying_type_t
underlying_type的便捷别名
constexpr bool is_member_function_pointer_v
is_member_function_pointer的便捷变量模板
constexpr bool is_null_pointer_v
is_null_pointer的便捷变量模板
constexpr bool is_integral_like_v
is_integral_like的便捷变量模板
constexpr bool is_pod_v
is_pod的便捷变量模板
constexpr bool is_pointer_interconvertible_with_class(Mem T::*mp) noexcept
判断成员指针是否指向类对象的起始位置
constexpr bool is_union_v
is_union的便捷变量模板
constexpr bool is_corresponding_member(M1 S1::*m1, M2 S2::*m2) noexcept
判断两个成员指针是否指向对应位置的成员
constexpr bool is_enum_v
is_enum的便捷变量模板
constexpr bool has_unique_object_representations_v
has_unique_object_representations的便捷变量模板
constexpr bool is_pointer_interconvertible_base_of_v
is_pointer_interconvertible_base_of的便捷变量模板
constexpr bool is_pointer_v
is_pointer的便捷变量模板
constexpr bool is_cstring_v
is_cstring的便捷变量模板
constexpr bool is_unbounded_array_v
is_unbounded_array的便捷变量模板
constexpr bool is_object_v
is_object的便捷变量模板
constexpr bool is_polymorphic_v
is_polymorphic的便捷变量模板
constexpr bool is_bounded_array_v
is_bounded_array的便捷变量模板
constexpr bool is_reference_v
is_reference的便捷变量模板
constexpr bool is_member_object_pointer_v
is_member_object_pointer的便捷变量模板
constexpr bool is_standard_layout_v
is_standard_layout的便捷变量模板
constexpr bool is_array_v
is_array的便捷变量模板
constexpr bool is_member_pointer_v
is_member_pointer的便捷变量模板
constexpr bool is_empty_v
is_empty的便捷变量模板
constexpr bool is_final_v
is_final的便捷变量模板
constexpr bool is_compound_v
is_compound的便捷变量模板
constexpr bool is_allocable_v
is_allocable的便捷变量模板
constexpr bool is_function_v
is_function的便捷变量模板
constexpr bool is_class_v
is_class的便捷变量模板
constexpr bool is_layout_compatible_v
is_layout_compatible的便捷变量模板
constexpr bool is_aggregate_v
is_aggregate的便捷变量模板
constexpr bool is_rvalue_reference_v
is_rvalue_reference的便捷变量模板
constexpr bool is_fundamental_v
is_fundamental的便捷变量模板
constexpr bool is_volatile_v
is_volatile的便捷变量模板
constexpr bool is_nothrow_arrow_v
is_nothrow_arrow的便捷变量模板
is_convertible< FromElement(*)[], ToElement(*)[]> is_array_convertible
判断数组元素类型FromElement是否可以转换为ToElement
constexpr bool is_array_convertible_v
is_array_convertible的便捷变量模板
constexpr bool is_convertible_v
is_convertible的便捷变量模板
constexpr bool is_nothrow_convertible_v
is_nothrow_convertible的便捷变量模板
unsigned char byte_t
字节类型,定义为无符号字符
typename remove_all_extents< T >::type remove_all_extents_t
remove_all_extents的便捷别名
copy_ref_t< From, copy_cv_t< From, To > > copy_cvref_t
同时复制cv和引用限定符
typename remove_pointer< From >::template bind_pointer_t< To > copy_pointer_t
复制指针限定符
typename remove_function_qualifiers< T >::type remove_function_qualifiers_t
remove_function_qualifiers的便捷别名
typename remove_cvref< T >::type remove_cvref_t
remove_cvref的便捷别名
typename remove_cv< From >::template bind_cv_t< To > copy_cv_t
复制cv限定符
typename remove_volatile< T >::type remove_volatile_t
remove_volatile的便捷别名
typename remove_reference< T >::type remove_reference_t
remove_reference的便捷别名
typename remove_const< T >::type remove_const_t
remove_const的便捷别名
typename remove_pointer< T >::type remove_pointer_t
remove_pointer的便捷别名
typename remove_cv< T >::type remove_cv_t
remove_cv的便捷别名
typename remove_reference< From >::template bind_ref_t< To > copy_ref_t
复制引用限定符
typename remove_extent< T >::type remove_extent_t
remove_extent的便捷别名
constexpr Iterator2 move(Iterator1 first, Iterator1 last, Iterator2 result) noexcept(noexcept(inner::__move_aux(first, last, result)))
移动范围元素
typename make_integer< Size, IsSigned >::type make_integer_t
make_integer的便捷别名
typename make_unsigned< T >::type make_unsigned_t
make_unsigned的便捷别名
typename make_signed< T >::type make_signed_t
make_signed的便捷别名
constexpr bool is_swappable_v
is_swappable的便捷变量模板
void swap()=delete
删除无参数的swap重载
constexpr T exchange(T &val, U &&new_val) noexcept(is_nothrow_move_constructible_v< T > &&is_nothrow_assignable_v< T &, U >)
将新值赋给对象并返回旧值
constexpr bool is_trivially_swappable_v
is_trivially_swappable的便捷变量模板
constexpr bool is_nothrow_swappable_v
is_nothrow_swappable的便捷变量模板
typename get_first_para< Types... >::type get_first_para_t
get_first_para的便捷别名
typename get_ptr_difference< T >::type get_ptr_difference_t
get_ptr_difference的便捷别名
typename replace_first_para< T, U >::type replace_first_para_t
replace_first_para的便捷别名
typename get_first_temp_para< Tmp >::type get_first_temp_para_t
get_first_temp_para的便捷别名
typename get_rebind_type< T, U >::type get_rebind_type_t
get_rebind_type的便捷别名
constexpr bool is_incrementible_v
iis_incrementible的便捷变量模板
constexpr bool is_allocator_v
is_allocator的便捷变量模板
constexpr bool has_base_v
has_base的便捷变量模板
constexpr bool has_construct_v
has_construct的便捷变量模板
constexpr bool is_decrementible_v
is_decrementible的便捷变量模板
constexpr bool is_iterable_v
is_iterable的便捷变量模板
constexpr bool is_maplike_v
is_maplike的便捷变量模板
constexpr bool is_specialization_v
is_specialization的便捷变量模板
typename common_type< Types... >::type common_type_t
common_type的便捷别名
decltype(true ? _NEFORCE declval< T1 >() :_NEFORCE declval< T2 >()) common_ternary_operator_t
三目运算符的公共类型推导
typename decay< T >::type decay_t
decay的便捷别名
typename detected_or< Default, Op, Args... >::type detected_or_t
detected_or的便捷别名,返回检测到的类型或默认类型
typename common_reference< Types... >::type common_reference_t
common_reference的便捷别名
inner::__detector< Default, void, Op, Args... > detected_or
检测Op<Args...>是否有效,如果无效则使用Default类型
constexpr decltype(auto) end(Container &cont) noexcept(noexcept(cont.end()))
获取容器的结束迭代器
constexpr T initialize() noexcept(is_nothrow_default_constructible< T >::value)
返回类型T的默认初始化值
#define NEFORCE_MACRO_RANGES_CV_REF_NOEXCEPT(MAC)
cv、引用和noexcept限定符列表宏
#define NEFORCE_MACRO_RANGES_CV(MAC)
cv限定符列表宏
#define NEFORCE_MACRO_RANGES_CV_REF(MAC)
cv和引用限定符列表宏
#define NEFORCE_MACRO_RANGE_ARITHMETIC(MAC)
所有算术类型列表宏
constexpr bool is_copy_constructible_v
is_copy_constructible的便捷变量模板
constexpr bool is_constructible_v
is_constructible的便捷变量模板
constexpr bool is_nothrow_copy_constructible_v
is_nothrow_copy_constructible的便捷变量模板
constexpr bool is_nothrow_default_constructible_v
is_nothrow_default_constructible的便捷变量模板
constexpr bool is_trivial_v
is_trivial的便捷变量模板
constexpr bool is_nothrow_copy_assignable_v
is_nothrow_copy_assignable的便捷变量模板
constexpr bool is_nothrow_move_constructible_v
is_nothrow_move_constructible的便捷变量模板
constexpr bool is_trivially_constructible_v
is_trivially_constructible的便捷变量模板
constexpr bool is_trivially_assignable_v
is_trivially_assignable的便捷变量模板
constexpr bool is_move_constructible_v
is_move_constructible的便捷变量模板
constexpr bool is_trivially_move_assignable_v
is_trivially_move_assignable的便捷变量模板
constexpr bool is_trivially_copy_assignable_v
is_trivially_copy_assignable的便捷变量模板
constexpr bool is_default_constructible_v
is_default_constructible的便捷变量模板
constexpr bool has_virtual_destructor_v
has_virtual_destructor的便捷变量模板
constexpr bool is_implicitly_default_constructible_v
is_implicitly_default_constructible的便捷变量模板
constexpr bool is_trivially_destructible_v
is_trivially_destructible的便捷变量模板
constexpr bool is_assignable_v
is_assignable的便捷变量模板
constexpr bool is_location_invariant_v
is_location_invariant的便捷变量模板
constexpr bool is_destructible_v
is_destructible的便捷变量模板
constexpr bool is_trivially_copy_constructible_v
is_trivially_copy_constructible的便捷变量模板
constexpr bool is_trivially_move_constructible_v
is_trivially_move_constructible的便捷变量模板
constexpr bool is_trivially_default_constructible_v
is_trivially_default_constructible的便捷变量模板
constexpr bool is_nothrow_constructible_v
is_nothrow_constructible的便捷变量模板
constexpr bool is_nothrow_assignable_v
is_nothrow_assignable的便捷变量模板
constexpr bool is_nothrow_move_assignable_v
is_nothrow_move_assignable的便捷变量模板
constexpr bool is_nothrow_destructible_v
is_nothrow_destructible的便捷变量模板
constexpr bool is_trivially_copyable_v
is_trivially_copyable的便捷变量模板
constexpr bool is_move_assignable_v
is_move_assignable的便捷变量模板
constexpr bool is_copy_assignable_v
is_copy_assignable的便捷变量模板
integral_constant< uint64_t, Value > uint64_constant
64位无符号整数常量包装器
constexpr bool negation_v
negation的便捷变量模板
constexpr bool conjunction_v
conjunction的便捷变量模板
typename conditional< Test, T1, T2 >::type conditional_t
conditional的便捷别名
constexpr bool is_any_of_v
is_any_of的便捷变量模板
integral_constant< uint32_t, Value > uint32_constant
32位无符号整数常量包装器
bool_constant< true > true_type
表示true的类型
constexpr bool is_same_v
is_same的便捷变量模板
constexpr bool disjunction_v
disjunction的便捷变量模板
typename type_identity< T >::type type_identity_t
type_identity的便捷别名
bool_constant< false > false_type
表示false的类型
integral_constant< bool, Value > bool_constant
布尔常量包装器
typename enable_if< Test, T >::type enable_if_t
enable_if的便捷别名
void swap(unique_ptr< T, Deleter > &lhs, unique_ptr< T, Deleter > &rhs) noexcept
交换两个unique_ptr
byte_t data[storage_size]
原始存储数据
static constexpr bool is_storable() noexcept
检查指定类型是否可以安全存储在aligned_union中
static constexpr size_t size_value
存储的实际大小
static constexpr size_t alignment_value
存储的对齐要求
integral_constant< T, Value > type
自身类型
constexpr value_type operator()() const noexcept
static constexpr bool value
判断Base是否是Derived的指针可互转换基类
wrapper bind_cv_t
将原类型的cv限定符应用到其他类型
wrapper bind_pointer_t
将原类型的指针限定符应用到其他类型
wrapper bind_ref_t
将原类型的引用限定符应用到其他类型