refactor(typetraits): replaces template class type traits with concepts for TypeTraits/PrimaryType.h
This commit is contained in:
@ -11,7 +11,7 @@ NAMESPACE_MODULE_BEGIN(Utility)
|
||||
|
||||
template <typename T, typename U>
|
||||
concept CAssignableFrom =
|
||||
TIsLValueReference<T>::Value &&
|
||||
CLValueReference<T> &&
|
||||
CCommonReferenceWith<const typename TRemoveReference<T>::Type&, const typename TRemoveReference<U>::Type&> &&
|
||||
requires(T A, U&& B)
|
||||
{
|
||||
|
@ -7,11 +7,9 @@ NAMESPACE_REDCRAFT_BEGIN
|
||||
NAMESPACE_MODULE_BEGIN(Redcraft)
|
||||
NAMESPACE_MODULE_BEGIN(Utility)
|
||||
|
||||
template <typename T> concept CIntegral = TIsIntegral<T>::Value;
|
||||
template <typename T> concept CSignedIntegral = CIntegral<T> && TIsSigned<T>::Value;
|
||||
template <typename T> concept CUnsignedIntegral = CIntegral<T> && TIsUnsigned<T>::Value;
|
||||
template <typename T> concept CNonBooleanIntegral = CIntegral<T> && !TIsSame<typename TRemoveCVRef<T>::Type, bool>::Value;
|
||||
template <typename T> concept CFloatingPoint = TIsFloatingPoint<T>::Value;
|
||||
|
||||
NAMESPACE_MODULE_END(Utility)
|
||||
NAMESPACE_MODULE_END(Redcraft)
|
||||
|
Reference in New Issue
Block a user