File indexing completed on 2026-05-03 08:13:26
0001
0002
0003
0004
0005
0006
0007
0008
0009 #ifndef _LIBCPP___CXX03___CONCEPTS_ARITHMETIC_H
0010 #define _LIBCPP___CXX03___CONCEPTS_ARITHMETIC_H
0011
0012 #include <__cxx03/__config>
0013 #include <__cxx03/__type_traits/is_floating_point.h>
0014 #include <__cxx03/__type_traits/is_integral.h>
0015 #include <__cxx03/__type_traits/is_signed.h>
0016 #include <__cxx03/__type_traits/is_signed_integer.h>
0017 #include <__cxx03/__type_traits/is_unsigned_integer.h>
0018
0019 #if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
0020 # pragma GCC system_header
0021 #endif
0022
0023 _LIBCPP_BEGIN_NAMESPACE_STD
0024
0025 #if _LIBCPP_STD_VER >= 20
0026
0027
0028
0029 template <class _Tp>
0030 concept integral = is_integral_v<_Tp>;
0031
0032 template <class _Tp>
0033 concept signed_integral = integral<_Tp> && is_signed_v<_Tp>;
0034
0035 template <class _Tp>
0036 concept unsigned_integral = integral<_Tp> && !signed_integral<_Tp>;
0037
0038 template <class _Tp>
0039 concept floating_point = is_floating_point_v<_Tp>;
0040
0041
0042
0043 template <class _Tp>
0044 concept __libcpp_unsigned_integer = __libcpp_is_unsigned_integer<_Tp>::value;
0045
0046 template <class _Tp>
0047 concept __libcpp_signed_integer = __libcpp_is_signed_integer<_Tp>::value;
0048
0049 template <class _Tp>
0050 concept __libcpp_integer = __libcpp_unsigned_integer<_Tp> || __libcpp_signed_integer<_Tp>;
0051
0052 #endif
0053
0054 _LIBCPP_END_NAMESPACE_STD
0055
0056 #endif