diff --git a/libcxx/include/__type_traits/is_abstract.h b/libcxx/include/__type_traits/is_abstract.h index f45acd58853a0..e2f68f2383c9f 100644 --- a/libcxx/include/__type_traits/is_abstract.h +++ b/libcxx/include/__type_traits/is_abstract.h @@ -19,7 +19,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template -struct _LIBCPP_NO_SPECIALIZATIONS is_abstract : public integral_constant {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_abstract : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_aggregate.h b/libcxx/include/__type_traits/is_aggregate.h index dc59c32f00aea..d1acec6b3e102 100644 --- a/libcxx/include/__type_traits/is_aggregate.h +++ b/libcxx/include/__type_traits/is_aggregate.h @@ -21,7 +21,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD #if _LIBCPP_STD_VER >= 17 template -struct _LIBCPP_NO_SPECIALIZATIONS is_aggregate : public integral_constant {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_aggregate : integral_constant {}; template _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_aggregate_v = __is_aggregate(_Tp); diff --git a/libcxx/include/__type_traits/is_arithmetic.h b/libcxx/include/__type_traits/is_arithmetic.h index 594ba543a83cb..0d5c29385f25d 100644 --- a/libcxx/include/__type_traits/is_arithmetic.h +++ b/libcxx/include/__type_traits/is_arithmetic.h @@ -22,7 +22,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template struct _LIBCPP_NO_SPECIALIZATIONS is_arithmetic - : public integral_constant::value || is_floating_point<_Tp>::value> {}; + : integral_constant::value || is_floating_point<_Tp>::value> {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_assignable.h b/libcxx/include/__type_traits/is_assignable.h index bbd59e15f1069..253e86ba774ea 100644 --- a/libcxx/include/__type_traits/is_assignable.h +++ b/libcxx/include/__type_traits/is_assignable.h @@ -30,8 +30,7 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_assignable_v = __is_assignab template struct _LIBCPP_NO_SPECIALIZATIONS is_copy_assignable - : public integral_constant, __add_lvalue_reference_t)> {}; + : integral_constant, __add_lvalue_reference_t)> {}; #if _LIBCPP_STD_VER >= 17 template @@ -40,7 +39,7 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_copy_assignable_v = is_copy_ template struct _LIBCPP_NO_SPECIALIZATIONS is_move_assignable - : public integral_constant, __add_rvalue_reference_t<_Tp>)> {}; + : integral_constant, __add_rvalue_reference_t<_Tp>)> {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_base_of.h b/libcxx/include/__type_traits/is_base_of.h index c71ed54374571..afbe8cac659e5 100644 --- a/libcxx/include/__type_traits/is_base_of.h +++ b/libcxx/include/__type_traits/is_base_of.h @@ -19,7 +19,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template -struct _LIBCPP_NO_SPECIALIZATIONS is_base_of : public integral_constant {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_base_of : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template @@ -30,8 +30,7 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_base_of_v = __is_base_of(_Bp # if __has_builtin(__builtin_is_virtual_base_of) template -struct _LIBCPP_NO_SPECIALIZATIONS is_virtual_base_of - : public bool_constant<__builtin_is_virtual_base_of(_Base, _Derived)> {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_virtual_base_of : bool_constant<__builtin_is_virtual_base_of(_Base, _Derived)> {}; template _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_virtual_base_of_v = __builtin_is_virtual_base_of(_Base, _Derived); diff --git a/libcxx/include/__type_traits/is_class.h b/libcxx/include/__type_traits/is_class.h index 0d64b8c7dbd1f..ba466f1bbddaf 100644 --- a/libcxx/include/__type_traits/is_class.h +++ b/libcxx/include/__type_traits/is_class.h @@ -19,7 +19,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template -struct _LIBCPP_NO_SPECIALIZATIONS is_class : public integral_constant {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_class : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_constructible.h b/libcxx/include/__type_traits/is_constructible.h index 20701e1f4d667..feafb70b1f684 100644 --- a/libcxx/include/__type_traits/is_constructible.h +++ b/libcxx/include/__type_traits/is_constructible.h @@ -21,8 +21,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template -struct _LIBCPP_NO_SPECIALIZATIONS is_constructible : public integral_constant { -}; +struct _LIBCPP_NO_SPECIALIZATIONS is_constructible : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template @@ -31,7 +30,7 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_constructible_v = __is_const template struct _LIBCPP_NO_SPECIALIZATIONS is_copy_constructible - : public integral_constant)> {}; + : integral_constant)> {}; #if _LIBCPP_STD_VER >= 17 template @@ -40,7 +39,7 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_copy_constructible_v = is_co template struct _LIBCPP_NO_SPECIALIZATIONS is_move_constructible - : public integral_constant)> {}; + : integral_constant)> {}; #if _LIBCPP_STD_VER >= 17 template @@ -48,7 +47,7 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_move_constructible_v = is_mo #endif template -struct _LIBCPP_NO_SPECIALIZATIONS is_default_constructible : public integral_constant {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_default_constructible : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_convertible.h b/libcxx/include/__type_traits/is_convertible.h index b142271550b94..cef3c4a764914 100644 --- a/libcxx/include/__type_traits/is_convertible.h +++ b/libcxx/include/__type_traits/is_convertible.h @@ -19,7 +19,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template -struct _LIBCPP_NO_SPECIALIZATIONS is_convertible : public integral_constant {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_convertible : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_core_convertible.h b/libcxx/include/__type_traits/is_core_convertible.h index 0de177c7771f4..93e23d24d6624 100644 --- a/libcxx/include/__type_traits/is_core_convertible.h +++ b/libcxx/include/__type_traits/is_core_convertible.h @@ -24,11 +24,11 @@ _LIBCPP_BEGIN_NAMESPACE_STD // and __is_core_convertible is true in C++17 and later. template -struct __is_core_convertible : public false_type {}; +struct __is_core_convertible : false_type {}; template struct __is_core_convertible<_Tp, _Up, decltype(static_cast(0)(static_cast<_Tp (*)()>(0)()))> - : public true_type {}; + : true_type {}; _LIBCPP_END_NAMESPACE_STD diff --git a/libcxx/include/__type_traits/is_destructible.h b/libcxx/include/__type_traits/is_destructible.h index bb521b86b8f18..ae661a46168b8 100644 --- a/libcxx/include/__type_traits/is_destructible.h +++ b/libcxx/include/__type_traits/is_destructible.h @@ -62,28 +62,28 @@ struct __destructible_imp; template struct __destructible_imp<_Tp, false> - : public integral_constant >::value> {}; + : integral_constant >::value> {}; template -struct __destructible_imp<_Tp, true> : public true_type {}; +struct __destructible_imp<_Tp, true> : true_type {}; template struct __destructible_false; template -struct __destructible_false<_Tp, false> : public __destructible_imp<_Tp, is_reference<_Tp>::value> {}; +struct __destructible_false<_Tp, false> : __destructible_imp<_Tp, is_reference<_Tp>::value> {}; template -struct __destructible_false<_Tp, true> : public false_type {}; +struct __destructible_false<_Tp, true> : false_type {}; template -struct is_destructible : public __destructible_false<_Tp, is_function<_Tp>::value> {}; +struct is_destructible : __destructible_false<_Tp, is_function<_Tp>::value> {}; template -struct is_destructible<_Tp[]> : public false_type {}; +struct is_destructible<_Tp[]> : false_type {}; template <> -struct is_destructible : public false_type {}; +struct is_destructible : false_type {}; # if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_empty.h b/libcxx/include/__type_traits/is_empty.h index a86058ed1bf5c..be6a0d1de7865 100644 --- a/libcxx/include/__type_traits/is_empty.h +++ b/libcxx/include/__type_traits/is_empty.h @@ -19,7 +19,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template -struct _LIBCPP_NO_SPECIALIZATIONS is_empty : public integral_constant {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_empty : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_enum.h b/libcxx/include/__type_traits/is_enum.h index c0d223f335989..4a58b193fe78e 100644 --- a/libcxx/include/__type_traits/is_enum.h +++ b/libcxx/include/__type_traits/is_enum.h @@ -19,7 +19,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template -struct _LIBCPP_NO_SPECIALIZATIONS is_enum : public integral_constant {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_enum : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_final.h b/libcxx/include/__type_traits/is_final.h index d78af6962cafa..e9ef1425c9760 100644 --- a/libcxx/include/__type_traits/is_final.h +++ b/libcxx/include/__type_traits/is_final.h @@ -19,11 +19,11 @@ _LIBCPP_BEGIN_NAMESPACE_STD template -struct __libcpp_is_final : public integral_constant {}; +struct __libcpp_is_final : integral_constant {}; #if _LIBCPP_STD_VER >= 14 template -struct _LIBCPP_NO_SPECIALIZATIONS is_final : public integral_constant {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_final : integral_constant {}; #endif #if _LIBCPP_STD_VER >= 17 diff --git a/libcxx/include/__type_traits/is_floating_point.h b/libcxx/include/__type_traits/is_floating_point.h index 51f94be7389f6..b87363fe5b357 100644 --- a/libcxx/include/__type_traits/is_floating_point.h +++ b/libcxx/include/__type_traits/is_floating_point.h @@ -20,14 +20,14 @@ _LIBCPP_BEGIN_NAMESPACE_STD // clang-format off -template struct __libcpp_is_floating_point : public false_type {}; -template <> struct __libcpp_is_floating_point : public true_type {}; -template <> struct __libcpp_is_floating_point : public true_type {}; -template <> struct __libcpp_is_floating_point : public true_type {}; +template struct __libcpp_is_floating_point : false_type {}; +template <> struct __libcpp_is_floating_point : true_type {}; +template <> struct __libcpp_is_floating_point : true_type {}; +template <> struct __libcpp_is_floating_point : true_type {}; // clang-format on template -struct _LIBCPP_NO_SPECIALIZATIONS is_floating_point : public __libcpp_is_floating_point<__remove_cv_t<_Tp> > {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_floating_point : __libcpp_is_floating_point<__remove_cv_t<_Tp> > {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_fundamental.h b/libcxx/include/__type_traits/is_fundamental.h index d108bfd940e3a..6236553cfb836 100644 --- a/libcxx/include/__type_traits/is_fundamental.h +++ b/libcxx/include/__type_traits/is_fundamental.h @@ -34,7 +34,7 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_fundamental_v = __is_fundame template struct is_fundamental - : public integral_constant::value || __is_null_pointer_v<_Tp> || is_arithmetic<_Tp>::value> {}; + : integral_constant::value || __is_null_pointer_v<_Tp> || is_arithmetic<_Tp>::value> {}; # if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_implicit_lifetime.h b/libcxx/include/__type_traits/is_implicit_lifetime.h index 34cf9b387120d..e5d1c05c437fc 100644 --- a/libcxx/include/__type_traits/is_implicit_lifetime.h +++ b/libcxx/include/__type_traits/is_implicit_lifetime.h @@ -22,7 +22,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD # if __has_builtin(__builtin_is_implicit_lifetime) template -struct _LIBCPP_NO_SPECIALIZATIONS is_implicit_lifetime : public bool_constant<__builtin_is_implicit_lifetime(_Tp)> {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_implicit_lifetime : bool_constant<__builtin_is_implicit_lifetime(_Tp)> {}; template _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_implicit_lifetime_v = __builtin_is_implicit_lifetime(_Tp); diff --git a/libcxx/include/__type_traits/is_literal_type.h b/libcxx/include/__type_traits/is_literal_type.h index 1c8c4d3b0b167..2e0df3ad1be38 100644 --- a/libcxx/include/__type_traits/is_literal_type.h +++ b/libcxx/include/__type_traits/is_literal_type.h @@ -21,7 +21,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD #if _LIBCPP_STD_VER <= 17 || defined(_LIBCPP_ENABLE_CXX20_REMOVED_TYPE_TRAITS) template struct _LIBCPP_DEPRECATED_IN_CXX17 _LIBCPP_NO_SPECIALIZATIONS is_literal_type - : public integral_constant {}; + : integral_constant {}; # if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_nothrow_assignable.h b/libcxx/include/__type_traits/is_nothrow_assignable.h index 6b7aa467ab1b4..903dead4435e8 100644 --- a/libcxx/include/__type_traits/is_nothrow_assignable.h +++ b/libcxx/include/__type_traits/is_nothrow_assignable.h @@ -21,8 +21,8 @@ _LIBCPP_BEGIN_NAMESPACE_STD template -struct _LIBCPP_NO_SPECIALIZATIONS is_nothrow_assignable - : public integral_constant {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_nothrow_assignable : integral_constant { +}; #if _LIBCPP_STD_VER >= 17 template @@ -31,9 +31,8 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_nothrow_assignable_v = __is_ template struct _LIBCPP_NO_SPECIALIZATIONS is_nothrow_copy_assignable - : public integral_constant< - bool, - __is_nothrow_assignable(__add_lvalue_reference_t<_Tp>, __add_lvalue_reference_t)> {}; + : integral_constant, __add_lvalue_reference_t)> {}; #if _LIBCPP_STD_VER >= 17 template @@ -42,9 +41,7 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_nothrow_copy_assignable_v = template struct _LIBCPP_NO_SPECIALIZATIONS is_nothrow_move_assignable - : public integral_constant, __add_rvalue_reference_t<_Tp>)> { -}; + : integral_constant, __add_rvalue_reference_t<_Tp>)> {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_nothrow_constructible.h b/libcxx/include/__type_traits/is_nothrow_constructible.h index 67cb6683b0ab8..bd14c1c40516f 100644 --- a/libcxx/include/__type_traits/is_nothrow_constructible.h +++ b/libcxx/include/__type_traits/is_nothrow_constructible.h @@ -22,7 +22,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template < class _Tp, class... _Args> struct _LIBCPP_NO_SPECIALIZATIONS is_nothrow_constructible - : public integral_constant {}; + : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template @@ -32,7 +32,7 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_nothrow_constructible_v = template struct _LIBCPP_NO_SPECIALIZATIONS is_nothrow_copy_constructible - : public integral_constant< bool, __is_nothrow_constructible(_Tp, __add_lvalue_reference_t)> {}; + : integral_constant)> {}; #if _LIBCPP_STD_VER >= 17 template @@ -42,7 +42,7 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_nothrow_copy_constructible_v template struct _LIBCPP_NO_SPECIALIZATIONS is_nothrow_move_constructible - : public integral_constant)> {}; + : integral_constant)> {}; #if _LIBCPP_STD_VER >= 17 template @@ -52,7 +52,7 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_nothrow_move_constructible_v template struct _LIBCPP_NO_SPECIALIZATIONS is_nothrow_default_constructible - : public integral_constant {}; + : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_nothrow_destructible.h b/libcxx/include/__type_traits/is_nothrow_destructible.h index 640de59a24d6c..81a34f98adf0a 100644 --- a/libcxx/include/__type_traits/is_nothrow_destructible.h +++ b/libcxx/include/__type_traits/is_nothrow_destructible.h @@ -32,23 +32,22 @@ template struct __libcpp_is_nothrow_destructible; template -struct __libcpp_is_nothrow_destructible : public false_type {}; +struct __libcpp_is_nothrow_destructible : false_type {}; template -struct __libcpp_is_nothrow_destructible - : public integral_constant().~_Tp()) > {}; +struct __libcpp_is_nothrow_destructible : integral_constant().~_Tp()) > {}; template -struct is_nothrow_destructible : public __libcpp_is_nothrow_destructible::value, _Tp> {}; +struct is_nothrow_destructible : __libcpp_is_nothrow_destructible::value, _Tp> {}; template -struct is_nothrow_destructible<_Tp[_Ns]> : public is_nothrow_destructible<_Tp> {}; +struct is_nothrow_destructible<_Tp[_Ns]> : is_nothrow_destructible<_Tp> {}; template -struct is_nothrow_destructible<_Tp&> : public true_type {}; +struct is_nothrow_destructible<_Tp&> : true_type {}; template -struct is_nothrow_destructible<_Tp&&> : public true_type {}; +struct is_nothrow_destructible<_Tp&&> : true_type {}; #endif // __has_builtin(__is_nothrow_destructible) diff --git a/libcxx/include/__type_traits/is_pod.h b/libcxx/include/__type_traits/is_pod.h index bc948c61a469d..8b805e946ae81 100644 --- a/libcxx/include/__type_traits/is_pod.h +++ b/libcxx/include/__type_traits/is_pod.h @@ -19,7 +19,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template -struct _LIBCPP_DEPRECATED_IN_CXX20 _LIBCPP_NO_SPECIALIZATIONS is_pod : public integral_constant {}; +struct _LIBCPP_DEPRECATED_IN_CXX20 _LIBCPP_NO_SPECIALIZATIONS is_pod : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_pointer.h b/libcxx/include/__type_traits/is_pointer.h index 22095ae6ea5d1..7bc78a6018662 100644 --- a/libcxx/include/__type_traits/is_pointer.h +++ b/libcxx/include/__type_traits/is_pointer.h @@ -32,9 +32,9 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_pointer_v = __is_pointer(_Tp #else // __has_builtin(__is_pointer) template -struct __libcpp_is_pointer : public false_type {}; +struct __libcpp_is_pointer : false_type {}; template -struct __libcpp_is_pointer<_Tp*> : public true_type {}; +struct __libcpp_is_pointer<_Tp*> : true_type {}; template struct __libcpp_remove_objc_qualifiers { @@ -50,7 +50,7 @@ template struct __libcpp_remove_objc_qualifiers<_Tp __unsafe_unretai # endif template -struct is_pointer : public __libcpp_is_pointer >::type> {}; +struct is_pointer : __libcpp_is_pointer >::type> {}; # if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_polymorphic.h b/libcxx/include/__type_traits/is_polymorphic.h index 1d375f4d61f37..4ced8ec0b4f9a 100644 --- a/libcxx/include/__type_traits/is_polymorphic.h +++ b/libcxx/include/__type_traits/is_polymorphic.h @@ -19,7 +19,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template -struct _LIBCPP_NO_SPECIALIZATIONS is_polymorphic : public integral_constant {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_polymorphic : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_reference.h b/libcxx/include/__type_traits/is_reference.h index 46cf386711ce6..9c98c13fd1f49 100644 --- a/libcxx/include/__type_traits/is_reference.h +++ b/libcxx/include/__type_traits/is_reference.h @@ -44,14 +44,14 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_rvalue_reference_v = __is_rv #else // __has_builtin(__is_lvalue_reference) template -struct is_lvalue_reference : public false_type {}; +struct is_lvalue_reference : false_type {}; template -struct is_lvalue_reference<_Tp&> : public true_type {}; +struct is_lvalue_reference<_Tp&> : true_type {}; template -struct is_rvalue_reference : public false_type {}; +struct is_rvalue_reference : false_type {}; template -struct is_rvalue_reference<_Tp&&> : public true_type {}; +struct is_rvalue_reference<_Tp&&> : true_type {}; # if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_reference_wrapper.h b/libcxx/include/__type_traits/is_reference_wrapper.h index 310a910040e8b..4bd8ebd44f05f 100644 --- a/libcxx/include/__type_traits/is_reference_wrapper.h +++ b/libcxx/include/__type_traits/is_reference_wrapper.h @@ -21,11 +21,11 @@ _LIBCPP_BEGIN_NAMESPACE_STD template -struct __is_reference_wrapper_impl : public false_type {}; +struct __is_reference_wrapper_impl : false_type {}; template -struct __is_reference_wrapper_impl > : public true_type {}; +struct __is_reference_wrapper_impl > : true_type {}; template -struct __is_reference_wrapper : public __is_reference_wrapper_impl<__remove_cv_t<_Tp> > {}; +struct __is_reference_wrapper : __is_reference_wrapper_impl<__remove_cv_t<_Tp> > {}; _LIBCPP_END_NAMESPACE_STD diff --git a/libcxx/include/__type_traits/is_scalar.h b/libcxx/include/__type_traits/is_scalar.h index b3398da79848c..102a0ca6f2fd2 100644 --- a/libcxx/include/__type_traits/is_scalar.h +++ b/libcxx/include/__type_traits/is_scalar.h @@ -45,7 +45,7 @@ struct __is_block<_Rp (^)(_Args...)> : true_type {}; // clang-format off template struct is_scalar - : public integral_constant< + : integral_constant< bool, is_arithmetic<_Tp>::value || is_member_pointer<_Tp>::value || is_pointer<_Tp>::value || @@ -55,7 +55,7 @@ struct is_scalar // clang-format on template <> -struct is_scalar : public true_type {}; +struct is_scalar : true_type {}; # if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_signed.h b/libcxx/include/__type_traits/is_signed.h index ea33bd6cef1e4..4aae921f293c9 100644 --- a/libcxx/include/__type_traits/is_signed.h +++ b/libcxx/include/__type_traits/is_signed.h @@ -33,19 +33,19 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_signed_v = __is_signed(_Tp); #else // __has_builtin(__is_signed) template ::value> -struct __libcpp_is_signed_impl : public _BoolConstant<(_Tp(-1) < _Tp(0))> {}; +struct __libcpp_is_signed_impl : _BoolConstant<(_Tp(-1) < _Tp(0))> {}; template -struct __libcpp_is_signed_impl<_Tp, false> : public true_type {}; // floating point +struct __libcpp_is_signed_impl<_Tp, false> : true_type {}; // floating point template ::value> -struct __libcpp_is_signed : public __libcpp_is_signed_impl<_Tp> {}; +struct __libcpp_is_signed : __libcpp_is_signed_impl<_Tp> {}; template -struct __libcpp_is_signed<_Tp, false> : public false_type {}; +struct __libcpp_is_signed<_Tp, false> : false_type {}; template -struct is_signed : public __libcpp_is_signed<_Tp> {}; +struct is_signed : __libcpp_is_signed<_Tp> {}; # if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_signed_integer.h b/libcxx/include/__type_traits/is_signed_integer.h index a3e19a66f2c74..62943902a1834 100644 --- a/libcxx/include/__type_traits/is_signed_integer.h +++ b/libcxx/include/__type_traits/is_signed_integer.h @@ -19,14 +19,14 @@ _LIBCPP_BEGIN_NAMESPACE_STD // clang-format off -template struct __libcpp_is_signed_integer : public false_type {}; -template <> struct __libcpp_is_signed_integer : public true_type {}; -template <> struct __libcpp_is_signed_integer : public true_type {}; -template <> struct __libcpp_is_signed_integer : public true_type {}; -template <> struct __libcpp_is_signed_integer : public true_type {}; -template <> struct __libcpp_is_signed_integer : public true_type {}; +template struct __libcpp_is_signed_integer : false_type {}; +template <> struct __libcpp_is_signed_integer : true_type {}; +template <> struct __libcpp_is_signed_integer : true_type {}; +template <> struct __libcpp_is_signed_integer : true_type {}; +template <> struct __libcpp_is_signed_integer : true_type {}; +template <> struct __libcpp_is_signed_integer : true_type {}; #if _LIBCPP_HAS_INT128 -template <> struct __libcpp_is_signed_integer<__int128_t> : public true_type {}; +template <> struct __libcpp_is_signed_integer<__int128_t> : true_type {}; #endif // clang-format on diff --git a/libcxx/include/__type_traits/is_standard_layout.h b/libcxx/include/__type_traits/is_standard_layout.h index c983ec6ba2ea4..1489d40219f25 100644 --- a/libcxx/include/__type_traits/is_standard_layout.h +++ b/libcxx/include/__type_traits/is_standard_layout.h @@ -19,7 +19,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template -struct _LIBCPP_NO_SPECIALIZATIONS is_standard_layout : public integral_constant {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_standard_layout : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_trivial.h b/libcxx/include/__type_traits/is_trivial.h index e249bf4760dd5..d42ba2ca1d14f 100644 --- a/libcxx/include/__type_traits/is_trivial.h +++ b/libcxx/include/__type_traits/is_trivial.h @@ -21,7 +21,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template struct _LIBCPP_DEPRECATED_IN_CXX26_( "Consider using is_trivially_copyable::value && is_trivially_default_constructible::value instead.") - _LIBCPP_NO_SPECIALIZATIONS is_trivial : public integral_constant {}; + _LIBCPP_NO_SPECIALIZATIONS is_trivial : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_trivially_assignable.h b/libcxx/include/__type_traits/is_trivially_assignable.h index e4d71f4991570..6548de991be4c 100644 --- a/libcxx/include/__type_traits/is_trivially_assignable.h +++ b/libcxx/include/__type_traits/is_trivially_assignable.h @@ -31,7 +31,7 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_trivially_assignable_v = __i template struct _LIBCPP_NO_SPECIALIZATIONS is_trivially_copy_assignable - : public integral_constant< + : integral_constant< bool, __is_trivially_assignable(__add_lvalue_reference_t<_Tp>, __add_lvalue_reference_t)> {}; @@ -43,9 +43,8 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_trivially_copy_assignable_v template struct _LIBCPP_NO_SPECIALIZATIONS is_trivially_move_assignable - : public integral_constant< - bool, - __is_trivially_assignable(__add_lvalue_reference_t<_Tp>, __add_rvalue_reference_t<_Tp>)> {}; + : integral_constant, __add_rvalue_reference_t<_Tp>)> { +}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_trivially_constructible.h b/libcxx/include/__type_traits/is_trivially_constructible.h index f9124270ec4a1..4e36c910cc042 100644 --- a/libcxx/include/__type_traits/is_trivially_constructible.h +++ b/libcxx/include/__type_traits/is_trivially_constructible.h @@ -32,7 +32,7 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_trivially_constructible_v = template struct _LIBCPP_NO_SPECIALIZATIONS is_trivially_copy_constructible - : public integral_constant)> {}; + : integral_constant)> {}; #if _LIBCPP_STD_VER >= 17 template @@ -42,7 +42,7 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_trivially_copy_constructible template struct _LIBCPP_NO_SPECIALIZATIONS is_trivially_move_constructible - : public integral_constant)> {}; + : integral_constant)> {}; #if _LIBCPP_STD_VER >= 17 template @@ -52,7 +52,7 @@ _LIBCPP_NO_SPECIALIZATIONS inline constexpr bool is_trivially_move_constructible template struct _LIBCPP_NO_SPECIALIZATIONS is_trivially_default_constructible - : public integral_constant {}; + : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_trivially_copyable.h b/libcxx/include/__type_traits/is_trivially_copyable.h index 87258c8639fd2..454ec0f2e7a05 100644 --- a/libcxx/include/__type_traits/is_trivially_copyable.h +++ b/libcxx/include/__type_traits/is_trivially_copyable.h @@ -20,8 +20,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template -struct _LIBCPP_NO_SPECIALIZATIONS is_trivially_copyable : public integral_constant { -}; +struct _LIBCPP_NO_SPECIALIZATIONS is_trivially_copyable : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_trivially_destructible.h b/libcxx/include/__type_traits/is_trivially_destructible.h index 3d885dcc6a7c5..6fa6f2a1537a2 100644 --- a/libcxx/include/__type_traits/is_trivially_destructible.h +++ b/libcxx/include/__type_traits/is_trivially_destructible.h @@ -23,13 +23,13 @@ _LIBCPP_BEGIN_NAMESPACE_STD template struct _LIBCPP_NO_SPECIALIZATIONS is_trivially_destructible - : public integral_constant {}; + : integral_constant {}; #elif __has_builtin(__has_trivial_destructor) template struct is_trivially_destructible - : public integral_constant::value&& __has_trivial_destructor(_Tp)> {}; + : integral_constant::value&& __has_trivial_destructor(_Tp)> {}; #else diff --git a/libcxx/include/__type_traits/is_union.h b/libcxx/include/__type_traits/is_union.h index f43447ec7d753..91a28eef28b49 100644 --- a/libcxx/include/__type_traits/is_union.h +++ b/libcxx/include/__type_traits/is_union.h @@ -19,7 +19,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD template -struct _LIBCPP_NO_SPECIALIZATIONS is_union : public integral_constant {}; +struct _LIBCPP_NO_SPECIALIZATIONS is_union : integral_constant {}; #if _LIBCPP_STD_VER >= 17 template diff --git a/libcxx/include/__type_traits/is_unsigned_integer.h b/libcxx/include/__type_traits/is_unsigned_integer.h index 86e42a1e8156a..74414a831e79a 100644 --- a/libcxx/include/__type_traits/is_unsigned_integer.h +++ b/libcxx/include/__type_traits/is_unsigned_integer.h @@ -19,14 +19,14 @@ _LIBCPP_BEGIN_NAMESPACE_STD // clang-format off -template struct __libcpp_is_unsigned_integer : public false_type {}; -template <> struct __libcpp_is_unsigned_integer : public true_type {}; -template <> struct __libcpp_is_unsigned_integer : public true_type {}; -template <> struct __libcpp_is_unsigned_integer : public true_type {}; -template <> struct __libcpp_is_unsigned_integer : public true_type {}; -template <> struct __libcpp_is_unsigned_integer : public true_type {}; +template struct __libcpp_is_unsigned_integer : false_type {}; +template <> struct __libcpp_is_unsigned_integer : true_type {}; +template <> struct __libcpp_is_unsigned_integer : true_type {}; +template <> struct __libcpp_is_unsigned_integer : true_type {}; +template <> struct __libcpp_is_unsigned_integer : true_type {}; +template <> struct __libcpp_is_unsigned_integer : true_type {}; #if _LIBCPP_HAS_INT128 -template <> struct __libcpp_is_unsigned_integer<__uint128_t> : public true_type {}; +template <> struct __libcpp_is_unsigned_integer<__uint128_t> : true_type {}; #endif // clang-format on