|
20 | 20 |
|
21 | 21 | namespace sus::choice_type::__private { |
22 | 22 |
|
23 | | -template <class ValueType1, class Types1, class ValueType2, class Types2> |
| 23 | +template <class TagType1, class Types1, class TagType2, class Types2> |
24 | 24 | struct ChoiceIsEqHelper; |
25 | 25 |
|
26 | | -template <class ValueType1, class... Types1, class ValueType2, class... Types2> |
27 | | -struct ChoiceIsEqHelper<ValueType1, TypeList<Types1...>, ValueType2, |
| 26 | +template <class TagType1, class... Types1, class TagType2, class... Types2> |
| 27 | +struct ChoiceIsEqHelper<TagType1, TypeList<Types1...>, TagType2, |
28 | 28 | TypeList<Types2...>> { |
29 | | - static constexpr bool value = (::sus::ops::Eq<ValueType1, ValueType2> && |
30 | | - ... && ::sus::ops::Eq<Types1, Types2>); |
| 29 | + static constexpr bool value = (::sus::ops::Eq<TagType1, TagType2> && ... && |
| 30 | + ::sus::ops::Eq<Types1, Types2>); |
31 | 31 | }; |
32 | 32 |
|
33 | 33 | // Out of line from the requires clause, and in a struct, to work around |
34 | 34 | // https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108067. |
35 | | -template <class ValueType1, class Types1, class ValueType2, class Types2> |
| 35 | +template <class TagType1, class Types1, class TagType2, class Types2> |
36 | 36 | concept ChoiceIsEq = |
37 | | - ChoiceIsEqHelper<ValueType1, Types1, ValueType2, Types2>::value; |
| 37 | + ChoiceIsEqHelper<TagType1, Types1, TagType2, Types2>::value; |
38 | 38 |
|
39 | | -template <class ValueType1, class Types1, class ValueType2, class Types2> |
| 39 | +template <class TagType1, class Types1, class TagType2, class Types2> |
40 | 40 | struct ChoiceIsOrdHelper; |
41 | 41 |
|
42 | | -template <class ValueType1, class... Types1, class ValueType2, class... Types2> |
43 | | -struct ChoiceIsOrdHelper<ValueType1, TypeList<Types1...>, ValueType2, |
| 42 | +template <class TagType1, class... Types1, class TagType2, class... Types2> |
| 43 | +struct ChoiceIsOrdHelper<TagType1, TypeList<Types1...>, TagType2, |
44 | 44 | TypeList<Types2...>> { |
45 | | - static constexpr bool value = (::sus::ops::Ord<ValueType1, ValueType2> && |
46 | | - ... && ::sus::ops::Ord<Types1, Types2>); |
| 45 | + static constexpr bool value = (::sus::ops::Ord<TagType1, TagType2> && ... && |
| 46 | + ::sus::ops::Ord<Types1, Types2>); |
47 | 47 | }; |
48 | 48 |
|
49 | 49 | // Out of line from the requires clause, and in a struct, to work around |
50 | 50 | // https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108067. |
51 | | -template <class ValueType1, class Types1, class ValueType2, class Types2> |
| 51 | +template <class TagType1, class Types1, class TagType2, class Types2> |
52 | 52 | concept ChoiceIsOrd = |
53 | | - ChoiceIsOrdHelper<ValueType1, Types1, ValueType2, Types2>::value; |
| 53 | + ChoiceIsOrdHelper<TagType1, Types1, TagType2, Types2>::value; |
54 | 54 |
|
55 | | -template <class ValueType1, class Types1, class ValueType2, class Types2> |
| 55 | +template <class TagType1, class Types1, class TagType2, class Types2> |
56 | 56 | struct ChoiceIsWeakOrdHelper; |
57 | 57 |
|
58 | | -template <class ValueType1, class... Types1, class ValueType2, class... Types2> |
59 | | -struct ChoiceIsWeakOrdHelper<ValueType1, TypeList<Types1...>, ValueType2, |
| 58 | +template <class TagType1, class... Types1, class TagType2, class... Types2> |
| 59 | +struct ChoiceIsWeakOrdHelper<TagType1, TypeList<Types1...>, TagType2, |
60 | 60 | TypeList<Types2...>> { |
61 | 61 | // clang-format off |
62 | 62 | static constexpr bool value = |
63 | | - ((!::sus::ops::Ord<ValueType1, ValueType2> || ... || |
| 63 | + ((!::sus::ops::Ord<TagType1, TagType2> || ... || |
64 | 64 | !::sus::ops::Ord<Types1, Types2>) |
65 | 65 | && |
66 | | - (::sus::ops::WeakOrd<ValueType1, ValueType2> && ... && |
| 66 | + (::sus::ops::WeakOrd<TagType1, TagType2> && ... && |
67 | 67 | ::sus::ops::WeakOrd<Types1, Types2>)); |
68 | 68 | // clang-format on |
69 | 69 | }; |
70 | 70 |
|
71 | 71 | // Out of line from the requires clause, in a struct, to work around |
72 | 72 | // https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108067. |
73 | | -template <class ValueType1, class Types1, class ValueType2, class Types2> |
| 73 | +template <class TagType1, class Types1, class TagType2, class Types2> |
74 | 74 | concept ChoiceIsWeakOrd = |
75 | | - ChoiceIsWeakOrdHelper<ValueType1, Types1, ValueType2, Types2>::value; |
| 75 | + ChoiceIsWeakOrdHelper<TagType1, Types1, TagType2, Types2>::value; |
76 | 76 |
|
77 | | -template <class ValueType1, class Types1, class ValueType2, class Types2> |
| 77 | +template <class TagType1, class Types1, class TagType2, class Types2> |
78 | 78 | struct ChoiceIsPartialOrdHelper; |
79 | 79 |
|
80 | | -template <class ValueType1, class... Types1, class ValueType2, class... Types2> |
81 | | -struct ChoiceIsPartialOrdHelper<ValueType1, TypeList<Types1...>, ValueType2, |
| 80 | +template <class TagType1, class... Types1, class TagType2, class... Types2> |
| 81 | +struct ChoiceIsPartialOrdHelper<TagType1, TypeList<Types1...>, TagType2, |
82 | 82 | TypeList<Types2...>> { |
83 | 83 | // clang-format off |
84 | 84 | static constexpr bool value = |
85 | | - (!::sus::ops::WeakOrd<ValueType1, ValueType2> || ... || |
| 85 | + (!::sus::ops::WeakOrd<TagType1, TagType2> || ... || |
86 | 86 | !::sus::ops::WeakOrd<Types1, Types2>) |
87 | 87 | && |
88 | | - (::sus::ops::PartialOrd<ValueType1, ValueType2> && ... && |
| 88 | + (::sus::ops::PartialOrd<TagType1, TagType2> && ... && |
89 | 89 | ::sus::ops::PartialOrd<Types1, Types2>); |
90 | 90 | // clang-format on |
91 | 91 | }; |
92 | 92 |
|
93 | 93 | // Out of line from the requires clause, in a struct, to work around |
94 | 94 | // https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108067. |
95 | | -template <class ValueType1, class Types1, class ValueType2, class Types2> |
| 95 | +template <class TagType1, class Types1, class TagType2, class Types2> |
96 | 96 | concept ChoiceIsPartialOrd = |
97 | | - ChoiceIsPartialOrdHelper<ValueType1, Types1, ValueType2, Types2>::value; |
| 97 | + ChoiceIsPartialOrdHelper<TagType1, Types1, TagType2, Types2>::value; |
98 | 98 |
|
99 | | -template <class ValueType1, class Types1, class ValueType2, class Types2> |
| 99 | +template <class TagType1, class Types1, class TagType2, class Types2> |
100 | 100 | struct ChoiceIsAnyOrdHelper; |
101 | 101 |
|
102 | | -template <class ValueType1, class... Types1, class ValueType2, class... Types2> |
103 | | -struct ChoiceIsAnyOrdHelper<ValueType1, TypeList<Types1...>, ValueType2, |
| 102 | +template <class TagType1, class... Types1, class TagType2, class... Types2> |
| 103 | +struct ChoiceIsAnyOrdHelper<TagType1, TypeList<Types1...>, TagType2, |
104 | 104 | TypeList<Types2...>> { |
105 | 105 | // clang-format off |
106 | 106 | static constexpr bool value = |
107 | | - (::sus::ops::PartialOrd<ValueType1, ValueType2> && ... && |
| 107 | + (::sus::ops::PartialOrd<TagType1, TagType2> && ... && |
108 | 108 | ::sus::ops::PartialOrd<Types1, Types2>); |
109 | 109 | // clang-format on |
110 | 110 | }; |
111 | 111 |
|
112 | 112 | // Out of line from the requires clause, in a struct, to work around |
113 | 113 | // https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108067. |
114 | | -template <class ValueType1, class Types1, class ValueType2, class Types2> |
| 114 | +template <class TagType1, class Types1, class TagType2, class Types2> |
115 | 115 | concept ChoiceIsAnyOrd = |
116 | | - ChoiceIsAnyOrdHelper<ValueType1, Types1, ValueType2, Types2>::value; |
| 116 | + ChoiceIsAnyOrdHelper<TagType1, Types1, TagType2, Types2>::value; |
117 | 117 |
|
118 | 118 | } // namespace sus::choice_type::__private |
0 commit comments