Warning, file /include/range/v3/compare.hpp was not indexed
or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017 #ifndef RANGES_V3_COMPARE_HPP
0018 #define RANGES_V3_COMPARE_HPP
0019
0020 #if __cplusplus > 201703L && __has_include(<compare>) && \
0021 defined(__cpp_concepts) && defined(__cpp_impl_three_way_comparison)
0022
0023 #include <compare>
0024 #include <type_traits>
0025
0026 namespace ranges
0027 {
0028 template<typename... Ts>
0029 struct common_comparison_category
0030 {
0031 using type = void;
0032 };
0033
0034 template<typename... Ts>
0035 requires ((std::is_same_v<Ts, std::partial_ordering> ||
0036 std::is_same_v<Ts, std::weak_ordering> ||
0037 std::is_same_v<Ts, std::strong_ordering>) && ...)
0038 struct common_comparison_category<Ts...> : std::common_type<Ts...>
0039 {};
0040
0041 template<typename... Ts>
0042 using common_comparison_category_t = typename common_comparison_category<Ts...>::type;
0043 }
0044
0045 #endif
0046 #endif