[libcxx-commits] [libcxx] 984f5f3 - [libc++][test] Adds spaceship support to macros.

Mark de Wever via libcxx-commits libcxx-commits at lists.llvm.org
Tue Jul 12 12:10:27 PDT 2022


Author: Mark de Wever
Date: 2022-07-12T21:10:23+02:00
New Revision: 984f5f3f6249ffac6a238da2d23ae20a433a0e99

URL: https://github.com/llvm/llvm-project/commit/984f5f3f6249ffac6a238da2d23ae20a433a0e99
DIFF: https://github.com/llvm/llvm-project/commit/984f5f3f6249ffac6a238da2d23ae20a433a0e99.diff

LOG: [libc++][test] Adds spaceship support to macros.

This was already reviewed as D128603. This contains only the updates to
the test script.

Differential Revision: https://reviews.llvm.org/D129578

Added: 
    

Modified: 
    libcxx/test/std/containers/associative/map/map.nonmember/op_compare.pass.cpp
    libcxx/test/std/containers/associative/multimap/multimap.nonmember/op_compare.pass.cpp
    libcxx/test/std/containers/associative/multiset/multiset.nonmember/op_compare.pass.cpp
    libcxx/test/std/containers/associative/set/set.nonmember/op_compare.pass.cpp
    libcxx/test/std/containers/sequences/array/compare.pass.cpp
    libcxx/test/std/containers/sequences/deque/compare.pass.cpp
    libcxx/test/std/containers/sequences/list/compare.pass.cpp
    libcxx/test/std/containers/sequences/vector.bool/compare.pass.cpp
    libcxx/test/std/containers/sequences/vector/compare.pass.cpp
    libcxx/test/std/containers/unord/unord.map/eq.pass.cpp
    libcxx/test/std/containers/unord/unord.multimap/eq.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.day/time.cal.day.nonmembers/comparisons.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.md/time.cal.md.nonmembers/comparisons.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.mdlast/comparisons.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.month/time.cal.month.nonmembers/comparisons.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.mwd/time.cal.mwd.nonmembers/comparisons.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.mwdlast/time.cal.mwdlast.nonmembers/comparisons.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.operators/month_day.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.operators/month_day_last.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.operators/month_weekday.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.operators/month_weekday_last.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.operators/year_month.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.operators/year_month_day.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.operators/year_month_day_last.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.operators/year_month_weekday.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.operators/year_month_weekday_last.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.wdidx/time.cal.wdidx.nonmembers/comparisons.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.wdlast/time.cal.wdlast.nonmembers/comparisons.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.weekday/time.cal.weekday.nonmembers/comparisons.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.year/time.cal.year.nonmembers/comparisons.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.ym/time.cal.ym.nonmembers/comparisons.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.ymd/time.cal.ymd.nonmembers/comparisons.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.ymdlast/time.cal.ymdlast.nonmembers/comparisons.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.ymwd/time.cal.ymwd.nonmembers/comparisons.pass.cpp
    libcxx/test/std/time/time.cal/time.cal.ymwdlast/time.cal.ymwdlast.nonmembers/comparisons.pass.cpp
    libcxx/test/support/test_comparisons.h

Removed: 
    


################################################################################
diff  --git a/libcxx/test/std/containers/associative/map/map.nonmember/op_compare.pass.cpp b/libcxx/test/std/containers/associative/map/map.nonmember/op_compare.pass.cpp
index cfeb02e043872..21d7669b42631 100644
--- a/libcxx/test/std/containers/associative/map/map.nonmember/op_compare.pass.cpp
+++ b/libcxx/test/std/containers/associative/map/map.nonmember/op_compare.pass.cpp
@@ -46,28 +46,28 @@ int main(int, char**) {
         m1.insert(value_type(1, "abc"));
         m2.insert(value_type(2, "abc"));
         const map_type& cm1 = m1, cm2 = m2;
-        assert(testComparisons6(cm1, cm2, false, true));
+        assert(testComparisons(cm1, cm2, false, true));
     }
     {
         map_type m1, m2;
         m1.insert(value_type(1, "abc"));
         m2.insert(value_type(1, "abc"));
         const map_type& cm1 = m1, cm2 = m2;
-        assert(testComparisons6(cm1, cm2, true, false));
+        assert(testComparisons(cm1, cm2, true, false));
     }
     {
         map_type m1, m2;
         m1.insert(value_type(1, "ab"));
         m2.insert(value_type(1, "abc"));
         const map_type& cm1 = m1, cm2 = m2;
-        assert(testComparisons6(cm1, cm2, false, true));
+        assert(testComparisons(cm1, cm2, false, true));
     }
     {
         map_type m1, m2;
         m1.insert(value_type(1, "abc"));
         m2.insert(value_type(1, "bcd"));
         const map_type& cm1 = m1, cm2 = m2;
-        assert(testComparisons6(cm1, cm2, false, true));
+        assert(testComparisons(cm1, cm2, false, true));
     }
     {
         map_type m1, m2;
@@ -75,7 +75,7 @@ int main(int, char**) {
         m2.insert(value_type(1, "abc"));
         m2.insert(value_type(2, "abc"));
         const map_type& cm1 = m1, cm2 = m2;
-        assert(testComparisons6(cm1, cm2, false, true));
+        assert(testComparisons(cm1, cm2, false, true));
     }
     return 0;
 }

diff  --git a/libcxx/test/std/containers/associative/multimap/multimap.nonmember/op_compare.pass.cpp b/libcxx/test/std/containers/associative/multimap/multimap.nonmember/op_compare.pass.cpp
index 83aeca5917f8c..be2143c68be7d 100644
--- a/libcxx/test/std/containers/associative/multimap/multimap.nonmember/op_compare.pass.cpp
+++ b/libcxx/test/std/containers/associative/multimap/multimap.nonmember/op_compare.pass.cpp
@@ -46,28 +46,28 @@ int main(int, char**) {
         m1.insert(value_type(1, "abc"));
         m2.insert(value_type(2, "abc"));
         const map_type& cm1 = m1, cm2 = m2;
-        assert(testComparisons6(cm1, cm2, false, true));
+        assert(testComparisons(cm1, cm2, false, true));
     }
     {
         map_type m1, m2;
         m1.insert(value_type(1, "abc"));
         m2.insert(value_type(1, "abc"));
         const map_type& cm1 = m1, cm2 = m2;
-        assert(testComparisons6(cm1, cm2, true, false));
+        assert(testComparisons(cm1, cm2, true, false));
     }
     {
         map_type m1, m2;
         m1.insert(value_type(1, "ab"));
         m2.insert(value_type(1, "abc"));
         const map_type& cm1 = m1, cm2 = m2;
-        assert(testComparisons6(cm1, cm2, false, true));
+        assert(testComparisons(cm1, cm2, false, true));
     }
     {
         map_type m1, m2;
         m1.insert(value_type(1, "abc"));
         m2.insert(value_type(1, "bcd"));
         const map_type& cm1 = m1, cm2 = m2;
-        assert(testComparisons6(cm1, cm2, false, true));
+        assert(testComparisons(cm1, cm2, false, true));
     }
     {
         map_type m1, m2;
@@ -75,7 +75,7 @@ int main(int, char**) {
         m2.insert(value_type(1, "abc"));
         m2.insert(value_type(2, "abc"));
         const map_type& cm1 = m1, cm2 = m2;
-        assert(testComparisons6(cm1, cm2, false, true));
+        assert(testComparisons(cm1, cm2, false, true));
     }
     {
         map_type m1, m2;
@@ -84,7 +84,7 @@ int main(int, char**) {
         m2.insert(value_type(1, "abc"));
         m2.insert(value_type(1, "bcd"));
         const map_type& cm1 = m1, cm2 = m2;
-        assert(testComparisons6(cm1, cm2, false, true));
+        assert(testComparisons(cm1, cm2, false, true));
     }
     return 0;
 }

diff  --git a/libcxx/test/std/containers/associative/multiset/multiset.nonmember/op_compare.pass.cpp b/libcxx/test/std/containers/associative/multiset/multiset.nonmember/op_compare.pass.cpp
index da142d2b87769..a8011f199775e 100644
--- a/libcxx/test/std/containers/associative/multiset/multiset.nonmember/op_compare.pass.cpp
+++ b/libcxx/test/std/containers/associative/multiset/multiset.nonmember/op_compare.pass.cpp
@@ -44,14 +44,14 @@ int main(int, char**) {
         s1.insert(1);
         s2.insert(2);
         const std::multiset<int>& cs1 = s1, cs2 = s2;
-        assert(testComparisons6(cs1, cs2, false, true));
+        assert(testComparisons(cs1, cs2, false, true));
     }
     {
         std::multiset<int> s1, s2;
         s1.insert(1);
         s2.insert(1);
         const std::multiset<int>& cs1 = s1, cs2 = s2;
-        assert(testComparisons6(cs1, cs2, true, false));
+        assert(testComparisons(cs1, cs2, true, false));
     }
     {
         std::multiset<int> s1, s2;
@@ -59,7 +59,7 @@ int main(int, char**) {
         s2.insert(1);
         s2.insert(2);
         const std::multiset<int>& cs1 = s1, cs2 = s2;
-        assert(testComparisons6(cs1, cs2, false, true));
+        assert(testComparisons(cs1, cs2, false, true));
     }
     {
         std::multiset<int> s1, s2;
@@ -68,7 +68,7 @@ int main(int, char**) {
         s2.insert(1);
         s2.insert(1);
         const std::multiset<int>& cs1 = s1, cs2 = s2;
-        assert(testComparisons6(cs1, cs2, false, true));
+        assert(testComparisons(cs1, cs2, false, true));
     }
     return 0;
 }

diff  --git a/libcxx/test/std/containers/associative/set/set.nonmember/op_compare.pass.cpp b/libcxx/test/std/containers/associative/set/set.nonmember/op_compare.pass.cpp
index 9e45e97f1d7dd..cc427fdd85a0f 100644
--- a/libcxx/test/std/containers/associative/set/set.nonmember/op_compare.pass.cpp
+++ b/libcxx/test/std/containers/associative/set/set.nonmember/op_compare.pass.cpp
@@ -44,14 +44,14 @@ int main(int, char**) {
         s1.insert(1);
         s2.insert(2);
         const std::set<int>& cs1 = s1, cs2 = s2;
-        assert(testComparisons6(cs1, cs2, false, true));
+        assert(testComparisons(cs1, cs2, false, true));
     }
     {
         std::set<int> s1, s2;
         s1.insert(1);
         s2.insert(1);
         const std::set<int>& cs1 = s1, cs2 = s2;
-        assert(testComparisons6(cs1, cs2, true, false));
+        assert(testComparisons(cs1, cs2, true, false));
     }
     {
         std::set<int> s1, s2;
@@ -59,7 +59,7 @@ int main(int, char**) {
         s2.insert(1);
         s2.insert(2);
         const std::set<int>& cs1 = s1, cs2 = s2;
-        assert(testComparisons6(cs1, cs2, false, true));
+        assert(testComparisons(cs1, cs2, false, true));
     }
     return 0;
 }

diff  --git a/libcxx/test/std/containers/sequences/array/compare.pass.cpp b/libcxx/test/std/containers/sequences/array/compare.pass.cpp
index d777b7e63bbe4..972600992980f 100644
--- a/libcxx/test/std/containers/sequences/array/compare.pass.cpp
+++ b/libcxx/test/std/containers/sequences/array/compare.pass.cpp
@@ -30,15 +30,15 @@ TEST_CONSTEXPR_CXX20 bool tests()
         const C c2 = {1, 2, 3};
         const C c3 = {3, 2, 1};
         const C c4 = {1, 2, 1};
-        assert(testComparisons6(c1, c2, true, false));
-        assert(testComparisons6(c1, c3, false, true));
-        assert(testComparisons6(c1, c4, false, false));
+        assert(testComparisons(c1, c2, true, false));
+        assert(testComparisons(c1, c3, false, true));
+        assert(testComparisons(c1, c4, false, false));
     }
     {
         typedef std::array<int, 0> C;
         const C c1 = {};
         const C c2 = {};
-        assert(testComparisons6(c1, c2, true, false));
+        assert(testComparisons(c1, c2, true, false));
     }
     {
         typedef std::array<LessAndEqComp, 3> C;
@@ -46,15 +46,15 @@ TEST_CONSTEXPR_CXX20 bool tests()
         const C c2 = {LessAndEqComp(1), LessAndEqComp(2), LessAndEqComp(3)};
         const C c3 = {LessAndEqComp(3), LessAndEqComp(2), LessAndEqComp(1)};
         const C c4 = {LessAndEqComp(1), LessAndEqComp(2), LessAndEqComp(1)};
-        assert(testComparisons6(c1, c2, true, false));
-        assert(testComparisons6(c1, c3, false, true));
-        assert(testComparisons6(c1, c4, false, false));
+        assert(testComparisons(c1, c2, true, false));
+        assert(testComparisons(c1, c3, false, true));
+        assert(testComparisons(c1, c4, false, false));
     }
     {
         typedef std::array<LessAndEqComp, 0> C;
         const C c1 = {};
         const C c2 = {};
-        assert(testComparisons6(c1, c2, true, false));
+        assert(testComparisons(c1, c2, true, false));
     }
 
     return true;

diff  --git a/libcxx/test/std/containers/sequences/deque/compare.pass.cpp b/libcxx/test/std/containers/sequences/deque/compare.pass.cpp
index 0ae9e6602fa71..fc7c07e2d0d48 100644
--- a/libcxx/test/std/containers/sequences/deque/compare.pass.cpp
+++ b/libcxx/test/std/containers/sequences/deque/compare.pass.cpp
@@ -41,78 +41,78 @@ int main(int, char**)
 {
     {
         const std::deque<int> d1, d2;
-        assert(testComparisons6(d1, d2, true, false));
+        assert(testComparisons(d1, d2, true, false));
     }
     {
         const std::deque<int> d1(1, 1), d2(1, 1);
-        assert(testComparisons6(d1, d2, true, false));
+        assert(testComparisons(d1, d2, true, false));
     }
     {
         int items[3] = {1, 2, 3};
         const std::deque<int> d1(items, items + 3);
         const std::deque<int> d2(items, items + 3);
-        assert(testComparisons6(d1, d2, true, false));
+        assert(testComparisons(d1, d2, true, false));
     }
     {
         const std::deque<int> d1(1, 1), d2;
-        assert(testComparisons6(d1, d2, false, false));
+        assert(testComparisons(d1, d2, false, false));
     }
     {
         const std::deque<int> d1(1, 1), d2(1, 2);
-        assert(testComparisons6(d1, d2, false, true));
+        assert(testComparisons(d1, d2, false, true));
     }
     {
         int items1[2] = {1, 2};
         int items2[2] = {1, 3};
         const std::deque<int> d1(items1, items1 + 2);
         const std::deque<int> d2(items2, items2 + 2);
-        assert(testComparisons6(d1, d2, false, true));
+        assert(testComparisons(d1, d2, false, true));
     }
     {
         int items1[2] = {2, 2};
         int items2[2] = {1, 3};
         const std::deque<int> d1(items1, items1 + 2);
         const std::deque<int> d2(items2, items2 + 2);
-        assert(testComparisons6(d1, d2, false, false));
+        assert(testComparisons(d1, d2, false, false));
     }
     {
         const std::deque<LessAndEqComp> d1, d2;
-        assert(testComparisons6(d1, d2, true, false));
+        assert(testComparisons(d1, d2, true, false));
     }
     {
         const std::deque<LessAndEqComp> d1(1, LessAndEqComp(1));
         const std::deque<LessAndEqComp> d2(1, LessAndEqComp(1));
-        assert(testComparisons6(d1, d2, true, false));
+        assert(testComparisons(d1, d2, true, false));
     }
     {
         LessAndEqComp items[3] = {LessAndEqComp(1), LessAndEqComp(2), LessAndEqComp(3)};
         const std::deque<LessAndEqComp> d1(items, items + 3);
         const std::deque<LessAndEqComp> d2(items, items + 3);
-        assert(testComparisons6(d1, d2, true, false));
+        assert(testComparisons(d1, d2, true, false));
     }
     {
         const std::deque<LessAndEqComp> d1(1, LessAndEqComp(1));
         const std::deque<LessAndEqComp> d2;
-        assert(testComparisons6(d1, d2, false, false));
+        assert(testComparisons(d1, d2, false, false));
     }
     {
         const std::deque<LessAndEqComp> d1(1, LessAndEqComp(1));
         const std::deque<LessAndEqComp> d2(1, LessAndEqComp(2));
-        assert(testComparisons6(d1, d2, false, true));
+        assert(testComparisons(d1, d2, false, true));
     }
     {
         LessAndEqComp items1[2] = {LessAndEqComp(1), LessAndEqComp(2)};
         LessAndEqComp items2[2] = {LessAndEqComp(1), LessAndEqComp(3)};
         const std::deque<LessAndEqComp> d1(items1, items1 + 2);
         const std::deque<LessAndEqComp> d2(items2, items2 + 2);
-        assert(testComparisons6(d1, d2, false, true));
+        assert(testComparisons(d1, d2, false, true));
     }
     {
         LessAndEqComp items1[2] = {LessAndEqComp(2), LessAndEqComp(2)};
         LessAndEqComp items2[2] = {LessAndEqComp(1), LessAndEqComp(3)};
         const std::deque<LessAndEqComp> d1(items1, items1 + 2);
         const std::deque<LessAndEqComp> d2(items2, items2 + 2);
-        assert(testComparisons6(d1, d2, false, false));
+        assert(testComparisons(d1, d2, false, false));
     }
 
     return 0;

diff  --git a/libcxx/test/std/containers/sequences/list/compare.pass.cpp b/libcxx/test/std/containers/sequences/list/compare.pass.cpp
index 59314922e3e80..1d6dd80745447 100644
--- a/libcxx/test/std/containers/sequences/list/compare.pass.cpp
+++ b/libcxx/test/std/containers/sequences/list/compare.pass.cpp
@@ -40,78 +40,78 @@
 int main(int, char**) {
     {
         const std::list<int> l1, l2;
-        assert(testComparisons6(l1, l2, true, false));
+        assert(testComparisons(l1, l2, true, false));
     }
     {
         const std::list<int> l1(1, 1), l2(1, 1);
-        assert(testComparisons6(l1, l2, true, false));
+        assert(testComparisons(l1, l2, true, false));
     }
     {
         int items[3] = {1, 2, 3};
         const std::list<int> l1(items, items + 3);
         const std::list<int> l2(items, items + 3);
-        assert(testComparisons6(l1, l2, true, false));
+        assert(testComparisons(l1, l2, true, false));
     }
     {
         const std::list<int> l1(1, 1), l2;
-        assert(testComparisons6(l1, l2, false, false));
+        assert(testComparisons(l1, l2, false, false));
     }
     {
         const std::list<int> l1(1, 1), l2(1, 2);
-        assert(testComparisons6(l1, l2, false, true));
+        assert(testComparisons(l1, l2, false, true));
     }
     {
         int items1[2] = {1, 2};
         int items2[2] = {1, 3};
         const std::list<int> l1(items1, items1 + 2);
         const std::list<int> l2(items2, items2 + 2);
-        assert(testComparisons6(l1, l2, false, true));
+        assert(testComparisons(l1, l2, false, true));
     }
     {
         int items1[2] = {2, 2};
         int items2[2] = {1, 3};
         const std::list<int> l1(items1, items1 + 2);
         const std::list<int> l2(items2, items2 + 2);
-        assert(testComparisons6(l1, l2, false, false));
+        assert(testComparisons(l1, l2, false, false));
     }
     {
         const std::list<LessAndEqComp> l1, l2;
-        assert(testComparisons6(l1, l2, true, false));
+        assert(testComparisons(l1, l2, true, false));
     }
     {
         const std::list<LessAndEqComp> l1(1, LessAndEqComp(1));
         const std::list<LessAndEqComp> l2(1, LessAndEqComp(1));
-        assert(testComparisons6(l1, l2, true, false));
+        assert(testComparisons(l1, l2, true, false));
     }
     {
         LessAndEqComp items[3] = {LessAndEqComp(1), LessAndEqComp(2), LessAndEqComp(3)};
         const std::list<LessAndEqComp> l1(items, items + 3);
         const std::list<LessAndEqComp> l2(items, items + 3);
-        assert(testComparisons6(l1, l2, true, false));
+        assert(testComparisons(l1, l2, true, false));
     }
     {
         const std::list<LessAndEqComp> l1(1, LessAndEqComp(1));
         const std::list<LessAndEqComp> l2;
-        assert(testComparisons6(l1, l2, false, false));
+        assert(testComparisons(l1, l2, false, false));
     }
     {
         const std::list<LessAndEqComp> l1(1, LessAndEqComp(1));
         const std::list<LessAndEqComp> l2(1, LessAndEqComp(2));
-        assert(testComparisons6(l1, l2, false, true));
+        assert(testComparisons(l1, l2, false, true));
     }
     {
         LessAndEqComp items1[2] = {LessAndEqComp(1), LessAndEqComp(2)};
         LessAndEqComp items2[2] = {LessAndEqComp(1), LessAndEqComp(3)};
         const std::list<LessAndEqComp> l1(items1, items1 + 2);
         const std::list<LessAndEqComp> l2(items2, items2 + 2);
-        assert(testComparisons6(l1, l2, false, true));
+        assert(testComparisons(l1, l2, false, true));
     }
     {
         LessAndEqComp items1[2] = {LessAndEqComp(2), LessAndEqComp(2)};
         LessAndEqComp items2[2] = {LessAndEqComp(1), LessAndEqComp(3)};
         const std::list<LessAndEqComp> l1(items1, items1 + 2);
         const std::list<LessAndEqComp> l2(items2, items2 + 2);
-        assert(testComparisons6(l1, l2, false, false));
+        assert(testComparisons(l1, l2, false, false));
     }
     return 0;
 }

diff  --git a/libcxx/test/std/containers/sequences/vector.bool/compare.pass.cpp b/libcxx/test/std/containers/sequences/vector.bool/compare.pass.cpp
index 60fede4f3061b..03b3b3d868d17 100644
--- a/libcxx/test/std/containers/sequences/vector.bool/compare.pass.cpp
+++ b/libcxx/test/std/containers/sequences/vector.bool/compare.pass.cpp
@@ -24,48 +24,48 @@ int main(int, char**) {
     typedef std::vector<bool> VB;
     {
         const VB v1, v2;
-        assert(testComparisons6(v1, v2, true, false));
+        assert(testComparisons(v1, v2, true, false));
     }
     {
         const VB v1(1, true);
         const VB v2(1, true);
-        assert(testComparisons6(v1, v2, true, false));
+        assert(testComparisons(v1, v2, true, false));
     }
     {
         const VB v1(1, false);
         const VB v2(1, true);
-        assert(testComparisons6(v1, v2, false, true));
+        assert(testComparisons(v1, v2, false, true));
     }
     {
         const VB v1, v2(1, true);
-        assert(testComparisons6(v1, v2, false, true));
+        assert(testComparisons(v1, v2, false, true));
     }
     {
         bool items1[3] = {false, true, false};
         bool items2[3] = {false, true, true};
         const VB v1(items1, items1 + 3);
         const VB v2(items2, items2 + 3);
-        assert(testComparisons6(v1, v2, false, true));
+        assert(testComparisons(v1, v2, false, true));
     }
     {
         bool items1[3] = {false, false, false};
         bool items2[3] = {false, true, false};
         const VB v1(items1, items1 + 3);
         const VB v2(items2, items2 + 3);
-        assert(testComparisons6(v1, v2, false, true));
+        assert(testComparisons(v1, v2, false, true));
     }
     {
         bool items1[2] = {false, true};
         bool items2[3] = {false, true, false};
         const VB v1(items1, items1 + 2);
         const VB v2(items2, items2 + 3);
-        assert(testComparisons6(v1, v2, false, true));
+        assert(testComparisons(v1, v2, false, true));
     }
     {
         bool items[3] = {false, true, false};
         const VB v1(items, items + 3);
         const VB v2(1, true);
-        assert(testComparisons6(v1, v2, false, true));
+        assert(testComparisons(v1, v2, false, true));
     }
     {
         assert( (std::vector<bool>() == std::vector<bool>()));

diff  --git a/libcxx/test/std/containers/sequences/vector/compare.pass.cpp b/libcxx/test/std/containers/sequences/vector/compare.pass.cpp
index 47d85a33c02e1..21ffb9296fa52 100644
--- a/libcxx/test/std/containers/sequences/vector/compare.pass.cpp
+++ b/libcxx/test/std/containers/sequences/vector/compare.pass.cpp
@@ -23,22 +23,22 @@
 int main(int, char**) {
     {
         const std::vector<int> c1, c2;
-        assert(testComparisons6(c1, c2, true, false));
+        assert(testComparisons(c1, c2, true, false));
     }
     {
         const std::vector<int> c1(1, 1), c2(1, 2);
-        assert(testComparisons6(c1, c2, false, true));
+        assert(testComparisons(c1, c2, false, true));
     }
     {
         const std::vector<int> c1, c2(1, 2);
-        assert(testComparisons6(c1, c2, false, true));
+        assert(testComparisons(c1, c2, false, true));
     }
     {
         int items1[3] = {1, 2, 1};
         int items2[3] = {1, 2, 2};
         const std::vector<int> c1(items1, items1 + 3);
         const std::vector<int> c2(items2, items2 + 3);
-        assert(testComparisons6(c1, c2, false, true));
+        assert(testComparisons(c1, c2, false, true));
     }
     {
         int items1[3] = {3, 2, 3};
@@ -46,66 +46,66 @@ int main(int, char**) {
         const std::vector<int> c1(items1, items1 + 3);
         const std::vector<int> c2(items2, items2 + 3);
 
-        assert(testComparisons6(c1, c2, false, false));
+        assert(testComparisons(c1, c2, false, false));
     }
     {
         int items1[2] = {1, 2};
         int items2[3] = {1, 2, 0};
         const std::vector<int> c1(items1, items1 + 2);
         const std::vector<int> c2(items2, items2 + 3);
-        assert(testComparisons6(c1, c2, false, true));
+        assert(testComparisons(c1, c2, false, true));
     }
     {
         int items1[3] = {1, 2, 0};
         const std::vector<int> c1(items1, items1 + 3);
         const std::vector<int> c2(1, 3);
-        assert(testComparisons6(c1, c2, false, true));
+        assert(testComparisons(c1, c2, false, true));
     }
     {
         const std::vector<LessAndEqComp> c1, c2;
-        assert(testComparisons6(c1, c2, true, false));
+        assert(testComparisons(c1, c2, true, false));
     }
     {
         const std::vector<LessAndEqComp> c1(1, LessAndEqComp(1));
         const std::vector<LessAndEqComp> c2(1, LessAndEqComp(1));
-        assert(testComparisons6(c1, c2, true, false));
+        assert(testComparisons(c1, c2, true, false));
     }
     {
         const std::vector<LessAndEqComp> c1(1, LessAndEqComp(1));
         const std::vector<LessAndEqComp> c2(1, LessAndEqComp(2));
-        assert(testComparisons6(c1, c2, false, true));
+        assert(testComparisons(c1, c2, false, true));
     }
     {
         const std::vector<LessAndEqComp> c1;
         const std::vector<LessAndEqComp> c2(1, LessAndEqComp(2));
-        assert(testComparisons6(c1, c2, false, true));
+        assert(testComparisons(c1, c2, false, true));
     }
     {
         LessAndEqComp items1[3] = {LessAndEqComp(1), LessAndEqComp(2), LessAndEqComp(2)};
         LessAndEqComp items2[3] = {LessAndEqComp(1), LessAndEqComp(2), LessAndEqComp(1)};
         const std::vector<LessAndEqComp> c1(items1, items1 + 3);
         const std::vector<LessAndEqComp> c2(items2, items2 + 3);
-        assert(testComparisons6(c1, c2, false, false));
+        assert(testComparisons(c1, c2, false, false));
     }
     {
         LessAndEqComp items1[3] = {LessAndEqComp(3), LessAndEqComp(3), LessAndEqComp(3)};
         LessAndEqComp items2[3] = {LessAndEqComp(3), LessAndEqComp(2), LessAndEqComp(3)};
         const std::vector<LessAndEqComp> c1(items1, items1 + 3);
         const std::vector<LessAndEqComp> c2(items2, items2 + 3);
-        assert(testComparisons6(c1, c2, false, false));
+        assert(testComparisons(c1, c2, false, false));
     }
     {
         LessAndEqComp items1[2] = {LessAndEqComp(1), LessAndEqComp(2)};
         LessAndEqComp items2[3] = {LessAndEqComp(1), LessAndEqComp(2), LessAndEqComp(0)};
         const std::vector<LessAndEqComp> c1(items1, items1 + 2);
         const std::vector<LessAndEqComp> c2(items2, items2 + 3);
-        assert(testComparisons6(c1, c2, false, true));
+        assert(testComparisons(c1, c2, false, true));
     }
     {
         LessAndEqComp items1[3] = {LessAndEqComp(1), LessAndEqComp(2), LessAndEqComp(0)};
         const std::vector<LessAndEqComp> c1(items1, items1 + 3);
         const std::vector<LessAndEqComp> c2(1, LessAndEqComp(3));
-        assert(testComparisons6(c1, c2, false, true));
+        assert(testComparisons(c1, c2, false, true));
     }
     {
         assert((std::vector<int>() == std::vector<int>()));

diff  --git a/libcxx/test/std/containers/unord/unord.map/eq.pass.cpp b/libcxx/test/std/containers/unord/unord.map/eq.pass.cpp
index 5b4dfe3f2bb4a..6fd22ab992ee3 100644
--- a/libcxx/test/std/containers/unord/unord.map/eq.pass.cpp
+++ b/libcxx/test/std/containers/unord/unord.map/eq.pass.cpp
@@ -46,7 +46,7 @@ int main(int, char**)
         };
         const C c1(std::begin(a), std::end(a));
         const C c2;
-        assert(testComparisons2(c1, c2, false));
+        assert(testEquality(c1, c2, false));
     }
     {
         typedef std::unordered_map<int, std::string> C;
@@ -64,7 +64,7 @@ int main(int, char**)
         };
         const C c1(std::begin(a), std::end(a));
         const C c2 = c1;
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
     }
     {
         typedef std::unordered_map<int, std::string> C;
@@ -83,11 +83,11 @@ int main(int, char**)
         C c1(std::begin(a), std::end(a));
         C c2 = c1;
         c2.rehash(30);
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
         c2.insert(P(90, "ninety"));
-        assert(testComparisons2(c1, c2, false));
+        assert(testEquality(c1, c2, false));
         c1.insert(P(90, "ninety"));
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
     }
     {
         typedef std::unordered_map<int, std::string> C;
@@ -105,10 +105,10 @@ int main(int, char**)
         };
         C c1(std::begin(a), std::end(a));
         C c2 = c1;
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
         c1.insert(P(90, "ninety"));
         c2.insert(P(100, "onehundred"));
-        assert(testComparisons2(c1, c2, false));
+        assert(testEquality(c1, c2, false));
     }
 #if TEST_STD_VER >= 11
     {
@@ -128,7 +128,7 @@ int main(int, char**)
         };
         const C c1(std::begin(a), std::end(a));
         const C c2;
-        assert(testComparisons2(c1, c2, false));
+        assert(testEquality(c1, c2, false));
     }
     {
         typedef std::unordered_map<int, std::string, std::hash<int>, std::equal_to<int>,
@@ -147,7 +147,7 @@ int main(int, char**)
         };
         const C c1(std::begin(a), std::end(a));
         const C c2 = c1;
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
     }
     {
         typedef std::unordered_map<int, std::string, std::hash<int>, std::equal_to<int>,
@@ -167,11 +167,11 @@ int main(int, char**)
         C c1(std::begin(a), std::end(a));
         C c2 = c1;
         c2.rehash(30);
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
         c2.insert(P(90, "ninety"));
-        assert(testComparisons2(c1, c2, false));
+        assert(testEquality(c1, c2, false));
         c1.insert(P(90, "ninety"));
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
     }
     {
         typedef std::unordered_map<int, std::string, std::hash<int>, std::equal_to<int>,
@@ -190,10 +190,10 @@ int main(int, char**)
         };
         C c1(std::begin(a), std::end(a));
         C c2 = c1;
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
         c1.insert(P(90, "ninety"));
         c2.insert(P(100, "onehundred"));
-        assert(testComparisons2(c1, c2, false));
+        assert(testEquality(c1, c2, false));
     }
 #endif
 

diff  --git a/libcxx/test/std/containers/unord/unord.multimap/eq.pass.cpp b/libcxx/test/std/containers/unord/unord.multimap/eq.pass.cpp
index 9b7ee304783a9..d0e578e190c0a 100644
--- a/libcxx/test/std/containers/unord/unord.multimap/eq.pass.cpp
+++ b/libcxx/test/std/containers/unord/unord.multimap/eq.pass.cpp
@@ -49,7 +49,7 @@ int main(int, char**)
         };
         const C c1(std::begin(a), std::end(a));
         const C c2;
-        assert(testComparisons2(c1, c2, false));
+        assert(testEquality(c1, c2, false));
     }
     {
         typedef std::unordered_multimap<int, std::string> C;
@@ -70,7 +70,7 @@ int main(int, char**)
         };
         const C c1(std::begin(a), std::end(a));
         const C c2 = c1;
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
     }
     {
         typedef std::unordered_multimap<int, std::string> C;
@@ -92,11 +92,11 @@ int main(int, char**)
         C c1(std::begin(a), std::end(a));
         C c2 = c1;
         c2.rehash(30);
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
         c2.insert(P(90, "ninety"));
-        assert(testComparisons2(c1, c2, false));
+        assert(testEquality(c1, c2, false));
         c1.insert(P(90, "ninety"));
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
     }
     {
         typedef std::unordered_multimap<int, std::string> C;
@@ -117,10 +117,10 @@ int main(int, char**)
         };
         C c1(std::begin(a), std::end(a));
         C c2 = c1;
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
         c1.insert(P(70, "seventy 2"));
         c2.insert(P(80, "eighty 2"));
-        assert(testComparisons2(c1, c2, false));
+        assert(testEquality(c1, c2, false));
     }
 #if TEST_STD_VER >= 11
     {
@@ -143,7 +143,7 @@ int main(int, char**)
         };
         const C c1(std::begin(a), std::end(a));
         const C c2;
-        assert(testComparisons2(c1, c2, false));
+        assert(testEquality(c1, c2, false));
     }
     {
         typedef std::unordered_multimap<int, std::string, std::hash<int>, std::equal_to<int>,
@@ -165,7 +165,7 @@ int main(int, char**)
         };
         const C c1(std::begin(a), std::end(a));
         const C c2 = c1;
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
     }
     {
         typedef std::unordered_multimap<int, std::string, std::hash<int>, std::equal_to<int>,
@@ -188,11 +188,11 @@ int main(int, char**)
         C c1(std::begin(a), std::end(a));
         C c2 = c1;
         c2.rehash(30);
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
         c2.insert(P(90, "ninety"));
-        assert(testComparisons2(c1, c2, false));
+        assert(testEquality(c1, c2, false));
         c1.insert(P(90, "ninety"));
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
     }
     {
         typedef std::unordered_multimap<int, std::string, std::hash<int>, std::equal_to<int>,
@@ -214,10 +214,10 @@ int main(int, char**)
         };
         C c1(std::begin(a), std::end(a));
         C c2 = c1;
-        assert(testComparisons2(c1, c2, true));
+        assert(testEquality(c1, c2, true));
         c1.insert(P(70, "seventy 2"));
         c2.insert(P(80, "eighty 2"));
-        assert(testComparisons2(c1, c2, false));
+        assert(testEquality(c1, c2, false));
     }
 #endif
 

diff  --git a/libcxx/test/std/time/time.cal/time.cal.day/time.cal.day.nonmembers/comparisons.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.day/time.cal.day.nonmembers/comparisons.pass.cpp
index fbae12e057883..1b5b712095ce7 100644
--- a/libcxx/test/std/time/time.cal/time.cal.day/time.cal.day.nonmembers/comparisons.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.day/time.cal.day.nonmembers/comparisons.pass.cpp
@@ -27,19 +27,19 @@ int main(int, char**)
 {
     using day = std::chrono::day;
 
-    AssertComparisons6AreNoexcept<day>();
-    AssertComparisons6ReturnBool<day>();
+    AssertComparisonsAreNoexcept<day>();
+    AssertComparisonsReturnBool<day>();
 
-    static_assert(testComparisons6Values<day>(0U, 0U), "");
-    static_assert(testComparisons6Values<day>(0U, 1U), "");
+    static_assert(testComparisonsValues<day>(0U, 0U), "");
+    static_assert(testComparisonsValues<day>(0U, 1U), "");
 
     //  Some 'ok' values as well
-    static_assert(testComparisons6Values<day>( 5U,  5U), "");
-    static_assert(testComparisons6Values<day>( 5U, 10U), "");
+    static_assert(testComparisonsValues<day>( 5U,  5U), "");
+    static_assert(testComparisonsValues<day>( 5U, 10U), "");
 
     for (unsigned i = 1; i < 10; ++i)
         for (unsigned j = 1; j < 10; ++j)
-            assert(testComparisons6Values<day>(i, j));
+            assert(testComparisonsValues<day>(i, j));
 
   return 0;
 }

diff  --git a/libcxx/test/std/time/time.cal/time.cal.md/time.cal.md.nonmembers/comparisons.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.md/time.cal.md.nonmembers/comparisons.pass.cpp
index d64e0e194ceaa..b284fc3c9c649 100644
--- a/libcxx/test/std/time/time.cal/time.cal.md/time.cal.md.nonmembers/comparisons.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.md/time.cal.md.nonmembers/comparisons.pass.cpp
@@ -32,20 +32,20 @@ int main(int, char**)
     using month     = std::chrono::month;
     using month_day = std::chrono::month_day;
 
-    AssertComparisons6AreNoexcept<month_day>();
-    AssertComparisons6ReturnBool<month_day>();
+    AssertComparisonsAreNoexcept<month_day>();
+    AssertComparisonsReturnBool<month_day>();
 
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         month_day{std::chrono::January, day{1}},
         month_day{std::chrono::January, day{1}},
         true, false), "");
 
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         month_day{std::chrono::January, day{1}},
         month_day{std::chrono::January, day{2}},
         false, true), "");
 
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         month_day{std::chrono::January,  day{1}},
         month_day{std::chrono::February, day{1}},
         false, true), "");
@@ -53,7 +53,7 @@ int main(int, char**)
     //  same day, 
diff erent months
     for (unsigned i = 1; i < 12; ++i)
         for (unsigned j = 1; j < 12; ++j)
-            assert((testComparisons6(
+            assert((testComparisons(
                 month_day{month{i}, day{1}},
                 month_day{month{j}, day{1}},
                 i == j, i < j )));
@@ -61,7 +61,7 @@ int main(int, char**)
     //  same month, 
diff erent days
     for (unsigned i = 1; i < 31; ++i)
         for (unsigned j = 1; j < 31; ++j)
-            assert((testComparisons6(
+            assert((testComparisons(
                 month_day{month{2}, day{i}},
                 month_day{month{2}, day{j}},
                 i == j, i < j )));

diff  --git a/libcxx/test/std/time/time.cal/time.cal.mdlast/comparisons.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.mdlast/comparisons.pass.cpp
index a83b045beb4a3..803d2021aac3d 100644
--- a/libcxx/test/std/time/time.cal/time.cal.mdlast/comparisons.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.mdlast/comparisons.pass.cpp
@@ -29,16 +29,16 @@ int main(int, char**)
     using month          = std::chrono::month;
     using month_day_last = std::chrono::month_day_last;
 
-    AssertComparisons6AreNoexcept<month_day_last>();
-    AssertComparisons6ReturnBool<month_day_last>();
+    AssertComparisonsAreNoexcept<month_day_last>();
+    AssertComparisonsReturnBool<month_day_last>();
 
-    static_assert( testComparisons6Values<month_day_last>(month{1}, month{1}), "");
-    static_assert( testComparisons6Values<month_day_last>(month{1}, month{2}), "");
+    static_assert( testComparisonsValues<month_day_last>(month{1}, month{1}), "");
+    static_assert( testComparisonsValues<month_day_last>(month{1}, month{2}), "");
 
     // same day, 
diff erent months
     for (unsigned i = 1; i <= 12; ++i)
         for (unsigned j = 1; j <= 12; ++j)
-            assert(testComparisons6Values<month_day_last>(month{i}, month{j}));
+            assert(testComparisonsValues<month_day_last>(month{i}, month{j}));
 
     return 0;
 }

diff  --git a/libcxx/test/std/time/time.cal/time.cal.month/time.cal.month.nonmembers/comparisons.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.month/time.cal.month.nonmembers/comparisons.pass.cpp
index 41f31cd084de2..8262b9194c988 100644
--- a/libcxx/test/std/time/time.cal/time.cal.month/time.cal.month.nonmembers/comparisons.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.month/time.cal.month.nonmembers/comparisons.pass.cpp
@@ -30,19 +30,19 @@ int main(int, char**)
 {
     using month = std::chrono::month;
 
-    AssertComparisons6AreNoexcept<month>();
-    AssertComparisons6ReturnBool<month>();
+    AssertComparisonsAreNoexcept<month>();
+    AssertComparisonsReturnBool<month>();
 
-    static_assert(testComparisons6Values<month>(0U ,0U), "");
-    static_assert(testComparisons6Values<month>(0U, 1U), "");
+    static_assert(testComparisonsValues<month>(0U ,0U), "");
+    static_assert(testComparisonsValues<month>(0U, 1U), "");
 
     //  Some 'ok' values as well
-    static_assert(testComparisons6Values<month>( 5U,  5U), "");
-    static_assert(testComparisons6Values<month>( 5U, 10U), "");
+    static_assert(testComparisonsValues<month>( 5U,  5U), "");
+    static_assert(testComparisonsValues<month>( 5U, 10U), "");
 
     for (unsigned i = 1; i <= 12; ++i)
         for (unsigned j = 1; j <= 12; ++j)
-            assert(testComparisons6Values<month>(i, j));
+            assert(testComparisonsValues<month>(i, j));
 
   return 0;
 }

diff  --git a/libcxx/test/std/time/time.cal/time.cal.mwd/time.cal.mwd.nonmembers/comparisons.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.mwd/time.cal.mwd.nonmembers/comparisons.pass.cpp
index c35599e3b0905..1f56785840b9f 100644
--- a/libcxx/test/std/time/time.cal/time.cal.mwd/time.cal.mwd.nonmembers/comparisons.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.mwd/time.cal.mwd.nonmembers/comparisons.pass.cpp
@@ -31,30 +31,30 @@ int main(int, char**)
     constexpr weekday Sunday = std::chrono::Sunday;
     constexpr weekday Monday = std::chrono::Monday;
 
-    AssertComparisons2AreNoexcept<month_weekday>();
-    AssertComparisons2ReturnBool<month_weekday>();
+    AssertEqualityAreNoexcept<month_weekday>();
+    AssertEqualityReturnBool<month_weekday>();
 
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         month_weekday{std::chrono::January, weekday_indexed{Sunday, 1}},
         month_weekday{std::chrono::January, weekday_indexed{Sunday, 1}},
         true), "");
 
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         month_weekday{std::chrono::January, weekday_indexed{Sunday, 1}},
         month_weekday{std::chrono::January, weekday_indexed{Sunday, 2}},
         false), "");
 
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         month_weekday{std::chrono::January,  weekday_indexed{Sunday, 1}},
         month_weekday{std::chrono::February, weekday_indexed{Sunday, 1}},
         false), "");
 
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         month_weekday{std::chrono::January, weekday_indexed{Monday, 1}},
         month_weekday{std::chrono::January, weekday_indexed{Sunday, 2}},
         false), "");
 
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         month_weekday{std::chrono::January,  weekday_indexed{Monday, 1}},
         month_weekday{std::chrono::February, weekday_indexed{Sunday, 1}},
         false), "");
@@ -62,7 +62,7 @@ int main(int, char**)
 //  same day, 
diff erent months
     for (unsigned i = 1; i < 12; ++i)
         for (unsigned j = 1; j < 12; ++j)
-            assert((testComparisons2(
+            assert((testEquality(
                 month_weekday{month{i}, weekday_indexed{Sunday, 1}},
                 month_weekday{month{j}, weekday_indexed{Sunday, 1}},
                 i == j)));
@@ -70,7 +70,7 @@ int main(int, char**)
 //  same month, 
diff erent weeks
     for (unsigned i = 1; i < 5; ++i)
         for (unsigned j = 1; j < 5; ++j)
-            assert((testComparisons2(
+            assert((testEquality(
                 month_weekday{month{2}, weekday_indexed{Sunday, i}},
                 month_weekday{month{2}, weekday_indexed{Sunday, j}},
                 i == j)));
@@ -78,7 +78,7 @@ int main(int, char**)
 //  same month, 
diff erent days
     for (unsigned i = 0; i < 6; ++i)
         for (unsigned j = 0; j < 6; ++j)
-            assert((testComparisons2(
+            assert((testEquality(
                 month_weekday{month{2}, weekday_indexed{weekday{i}, 2}},
                 month_weekday{month{2}, weekday_indexed{weekday{j}, 2}},
                 i == j)));

diff  --git a/libcxx/test/std/time/time.cal/time.cal.mwdlast/time.cal.mwdlast.nonmembers/comparisons.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.mwdlast/time.cal.mwdlast.nonmembers/comparisons.pass.cpp
index 91b5e4f63773e..740ffea620e5e 100644
--- a/libcxx/test/std/time/time.cal/time.cal.mwdlast/time.cal.mwdlast.nonmembers/comparisons.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.mwdlast/time.cal.mwdlast.nonmembers/comparisons.pass.cpp
@@ -35,15 +35,15 @@ int main(int, char**)
     constexpr weekday Tuesday = std::chrono::Tuesday;
     constexpr weekday Wednesday = std::chrono::Wednesday;
 
-    AssertComparisons2AreNoexcept<month_weekday_last>();
-    AssertComparisons2ReturnBool<month_weekday_last>();
+    AssertEqualityAreNoexcept<month_weekday_last>();
+    AssertEqualityReturnBool<month_weekday_last>();
 
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         month_weekday_last{std::chrono::January, weekday_last{Tuesday}},
         month_weekday_last{std::chrono::January, weekday_last{Tuesday}},
         true), "");
 
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         month_weekday_last{std::chrono::January, weekday_last{Tuesday}},
         month_weekday_last{std::chrono::January, weekday_last{Wednesday}},
         false), "");
@@ -51,7 +51,7 @@ int main(int, char**)
     //  vary the months
     for (unsigned i = 1; i < 12; ++i)
         for (unsigned j = 1; j < 12; ++j)
-            assert((testComparisons2(
+            assert((testEquality(
                 month_weekday_last{month{i}, weekday_last{Tuesday}},
                 month_weekday_last{month{j}, weekday_last{Tuesday}},
             i == j)));
@@ -59,13 +59,13 @@ int main(int, char**)
     //  vary the weekday
     for (unsigned i = 0; i < 6; ++i)
         for (unsigned j = 0; j < 6; ++j)
-            assert((testComparisons2(
+            assert((testEquality(
                 month_weekday_last{January, weekday_last{weekday{i}}},
                 month_weekday_last{January, weekday_last{weekday{j}}},
             i == j)));
 
     //  both 
diff erent
-    assert((testComparisons2(
+    assert((testEquality(
         month_weekday_last{month{1}, weekday_last{weekday{1}}},
         month_weekday_last{month{2}, weekday_last{weekday{2}}},
     false)));

diff  --git a/libcxx/test/std/time/time.cal/time.cal.operators/month_day.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.operators/month_day.pass.cpp
index 4b90eb238fd4e..41fad0e415c68 100644
--- a/libcxx/test/std/time/time.cal/time.cal.operators/month_day.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.operators/month_day.pass.cpp
@@ -36,7 +36,6 @@
 #include <cassert>
 
 #include "test_macros.h"
-#include "test_comparisons.h"
 
 int main(int, char**)
 {

diff  --git a/libcxx/test/std/time/time.cal/time.cal.operators/month_day_last.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.operators/month_day_last.pass.cpp
index ae9d7e4fcab56..fdf241a12373c 100644
--- a/libcxx/test/std/time/time.cal/time.cal.operators/month_day_last.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.operators/month_day_last.pass.cpp
@@ -39,7 +39,6 @@
 #include <cassert>
 
 #include "test_macros.h"
-#include "test_comparisons.h"
 
 int main(int, char**)
 {

diff  --git a/libcxx/test/std/time/time.cal/time.cal.operators/month_weekday.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.operators/month_weekday.pass.cpp
index 7c0e6e6b69a83..1375550929ebb 100644
--- a/libcxx/test/std/time/time.cal/time.cal.operators/month_weekday.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.operators/month_weekday.pass.cpp
@@ -42,7 +42,6 @@
 #include <cassert>
 
 #include "test_macros.h"
-#include "test_comparisons.h"
 
 int main(int, char**)
 {

diff  --git a/libcxx/test/std/time/time.cal/time.cal.operators/month_weekday_last.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.operators/month_weekday_last.pass.cpp
index 02e2a896ba06d..97451f0d75b7d 100644
--- a/libcxx/test/std/time/time.cal/time.cal.operators/month_weekday_last.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.operators/month_weekday_last.pass.cpp
@@ -34,7 +34,6 @@
 #include <cassert>
 
 #include "test_macros.h"
-#include "test_comparisons.h"
 
 int main(int, char**)
 {

diff  --git a/libcxx/test/std/time/time.cal/time.cal.operators/year_month.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.operators/year_month.pass.cpp
index 7ce07f74f7926..b59e8e1a8b7bb 100644
--- a/libcxx/test/std/time/time.cal/time.cal.operators/year_month.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.operators/year_month.pass.cpp
@@ -23,7 +23,6 @@
 #include <cassert>
 
 #include "test_macros.h"
-#include "test_comparisons.h"
 
 int main(int, char**)
 {

diff  --git a/libcxx/test/std/time/time.cal/time.cal.operators/year_month_day.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.operators/year_month_day.pass.cpp
index db1a557c4b67d..3c4371a9d1a5b 100644
--- a/libcxx/test/std/time/time.cal/time.cal.operators/year_month_day.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.operators/year_month_day.pass.cpp
@@ -40,7 +40,6 @@
 #include <cassert>
 
 #include "test_macros.h"
-#include "test_comparisons.h"
 
 int main(int, char**)
 {

diff  --git a/libcxx/test/std/time/time.cal/time.cal.operators/year_month_day_last.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.operators/year_month_day_last.pass.cpp
index 7648999b7cbd1..00ddda6858e57 100644
--- a/libcxx/test/std/time/time.cal/time.cal.operators/year_month_day_last.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.operators/year_month_day_last.pass.cpp
@@ -36,7 +36,6 @@
 #include <cassert>
 
 #include "test_macros.h"
-#include "test_comparisons.h"
 
 int main(int, char**)
 {

diff  --git a/libcxx/test/std/time/time.cal/time.cal.operators/year_month_weekday.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.operators/year_month_weekday.pass.cpp
index b4938f839374e..59d3875287431 100644
--- a/libcxx/test/std/time/time.cal/time.cal.operators/year_month_weekday.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.operators/year_month_weekday.pass.cpp
@@ -35,7 +35,6 @@
 #include <cassert>
 
 #include "test_macros.h"
-#include "test_comparisons.h"
 
 int main(int, char**)
 {

diff  --git a/libcxx/test/std/time/time.cal/time.cal.operators/year_month_weekday_last.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.operators/year_month_weekday_last.pass.cpp
index b4691ce095e19..33258b76d468a 100644
--- a/libcxx/test/std/time/time.cal/time.cal.operators/year_month_weekday_last.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.operators/year_month_weekday_last.pass.cpp
@@ -37,7 +37,6 @@
 #include <cassert>
 
 #include "test_macros.h"
-#include "test_comparisons.h"
 
 int main(int, char**)
 {

diff  --git a/libcxx/test/std/time/time.cal/time.cal.wdidx/time.cal.wdidx.nonmembers/comparisons.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.wdidx/time.cal.wdidx.nonmembers/comparisons.pass.cpp
index c56c2442c2aed..95f409a44dc10 100644
--- a/libcxx/test/std/time/time.cal/time.cal.wdidx/time.cal.wdidx.nonmembers/comparisons.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.wdidx/time.cal.wdidx.nonmembers/comparisons.pass.cpp
@@ -27,8 +27,8 @@ int main(int, char**)
     using weekday         = std::chrono::weekday;
     using weekday_indexed = std::chrono::weekday_indexed;
 
-    AssertComparisons2AreNoexcept<weekday_indexed>();
-    AssertComparisons2ReturnBool<weekday_indexed>();
+    AssertEqualityAreNoexcept<weekday_indexed>();
+    AssertEqualityReturnBool<weekday_indexed>();
 
     static_assert( (weekday_indexed{} == weekday_indexed{}), "");
     static_assert(!(weekday_indexed{} != weekday_indexed{}), "");

diff  --git a/libcxx/test/std/time/time.cal/time.cal.wdlast/time.cal.wdlast.nonmembers/comparisons.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.wdlast/time.cal.wdlast.nonmembers/comparisons.pass.cpp
index bb02729552a09..4845fa82de69a 100644
--- a/libcxx/test/std/time/time.cal/time.cal.wdlast/time.cal.wdlast.nonmembers/comparisons.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.wdlast/time.cal.wdlast.nonmembers/comparisons.pass.cpp
@@ -26,19 +26,19 @@ int main(int, char**)
     using weekday      = std::chrono::weekday;
     using weekday_last = std::chrono::weekday_last;
 
-    AssertComparisons2AreNoexcept<weekday_last>();
-    AssertComparisons2ReturnBool<weekday_last>();
+    AssertEqualityAreNoexcept<weekday_last>();
+    AssertEqualityReturnBool<weekday_last>();
 
-    static_assert(testComparisons2Values<weekday_last>(weekday{0}, weekday{0}), "");
-    static_assert(testComparisons2Values<weekday_last>(weekday{0}, weekday{1}), "");
+    static_assert(testEqualityValues<weekday_last>(weekday{0}, weekday{0}), "");
+    static_assert(testEqualityValues<weekday_last>(weekday{0}, weekday{1}), "");
 
     //  Some 'ok' values as well
-    static_assert(testComparisons2Values<weekday_last>(weekday{2}, weekday{2}), "");
-    static_assert(testComparisons2Values<weekday_last>(weekday{2}, weekday{3}), "");
+    static_assert(testEqualityValues<weekday_last>(weekday{2}, weekday{2}), "");
+    static_assert(testEqualityValues<weekday_last>(weekday{2}, weekday{3}), "");
 
     for (unsigned i = 0; i < 6; ++i)
         for (unsigned j = 0; j < 6; ++j)
-            assert(testComparisons2Values<weekday_last>(weekday{i}, weekday{j}));
+            assert(testEqualityValues<weekday_last>(weekday{i}, weekday{j}));
 
     return 0;
 }

diff  --git a/libcxx/test/std/time/time.cal/time.cal.weekday/time.cal.weekday.nonmembers/comparisons.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.weekday/time.cal.weekday.nonmembers/comparisons.pass.cpp
index 759a78b61a5ce..33d8cd9f776d2 100644
--- a/libcxx/test/std/time/time.cal/time.cal.weekday/time.cal.weekday.nonmembers/comparisons.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.weekday/time.cal.weekday.nonmembers/comparisons.pass.cpp
@@ -25,19 +25,19 @@ int main(int, char**)
 {
     using weekday = std::chrono::weekday;
 
-    AssertComparisons2AreNoexcept<weekday>();
-    AssertComparisons2ReturnBool<weekday>();
+    AssertEqualityAreNoexcept<weekday>();
+    AssertEqualityReturnBool<weekday>();
 
-    static_assert(testComparisons2Values<weekday>(0U ,0U), "");
-    static_assert(testComparisons2Values<weekday>(0U, 1U), "");
+    static_assert(testEqualityValues<weekday>(0U ,0U), "");
+    static_assert(testEqualityValues<weekday>(0U, 1U), "");
 
     //  Some 'ok' values as well
-    static_assert(testComparisons2Values<weekday>(5U, 5U), "");
-    static_assert(testComparisons2Values<weekday>(5U, 2U), "");
+    static_assert(testEqualityValues<weekday>(5U, 5U), "");
+    static_assert(testEqualityValues<weekday>(5U, 2U), "");
 
     for (unsigned i = 0; i < 6; ++i)
         for (unsigned j = 0; j < 6; ++j)
-            assert(testComparisons2Values<weekday>(i, j));
+            assert(testEqualityValues<weekday>(i, j));
 
     return 0;
 }

diff  --git a/libcxx/test/std/time/time.cal/time.cal.year/time.cal.year.nonmembers/comparisons.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.year/time.cal.year.nonmembers/comparisons.pass.cpp
index 9d92055e64ba7..8b05daeb1304f 100644
--- a/libcxx/test/std/time/time.cal/time.cal.year/time.cal.year.nonmembers/comparisons.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.year/time.cal.year.nonmembers/comparisons.pass.cpp
@@ -30,19 +30,19 @@ int main(int, char**)
 {
     using year = std::chrono::year;
 
-    AssertComparisons6AreNoexcept<year>();
-    AssertComparisons6ReturnBool<year>();
+    AssertComparisonsAreNoexcept<year>();
+    AssertComparisonsReturnBool<year>();
 
-    static_assert(testComparisons6Values<year>(0,0), "");
-    static_assert(testComparisons6Values<year>(0,1), "");
+    static_assert(testComparisonsValues<year>(0,0), "");
+    static_assert(testComparisonsValues<year>(0,1), "");
 
     //  Some 'ok' values as well
-    static_assert(testComparisons6Values<year>( 5, 5), "");
-    static_assert(testComparisons6Values<year>( 5,10), "");
+    static_assert(testComparisonsValues<year>( 5, 5), "");
+    static_assert(testComparisonsValues<year>( 5,10), "");
 
     for (int i = 1; i < 10; ++i)
         for (int j = 1; j < 10; ++j)
-            assert(testComparisons6Values<year>(i, j));
+            assert(testComparisonsValues<year>(i, j));
 
     return 0;
 }

diff  --git a/libcxx/test/std/time/time.cal/time.cal.ym/time.cal.ym.nonmembers/comparisons.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.ym/time.cal.ym.nonmembers/comparisons.pass.cpp
index 031b512e4e3d1..4ff44688154e7 100644
--- a/libcxx/test/std/time/time.cal/time.cal.ym/time.cal.ym.nonmembers/comparisons.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.ym/time.cal.ym.nonmembers/comparisons.pass.cpp
@@ -32,20 +32,20 @@ int main(int, char**)
     using month      = std::chrono::month;
     using year_month = std::chrono::year_month;
 
-    AssertComparisons6AreNoexcept<year_month>();
-    AssertComparisons6ReturnBool<year_month>();
+    AssertComparisonsAreNoexcept<year_month>();
+    AssertComparisonsReturnBool<year_month>();
 
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month{year{1234}, std::chrono::January},
         year_month{year{1234}, std::chrono::January},
         true, false), "");
 
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month{year{1234}, std::chrono::January},
         year_month{year{1234}, std::chrono::February},
         false, true), "");
 
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month{year{1234}, std::chrono::January},
         year_month{year{1235}, std::chrono::January},
         false, true), "");
@@ -53,7 +53,7 @@ int main(int, char**)
     //  same year, 
diff erent months
     for (unsigned i = 1; i < 12; ++i)
         for (unsigned j = 1; j < 12; ++j)
-            assert((testComparisons6(
+            assert((testComparisons(
                 year_month{year{1234}, month{i}},
                 year_month{year{1234}, month{j}},
                 i == j, i < j )));
@@ -61,7 +61,7 @@ int main(int, char**)
     //  same month, 
diff erent years
     for (int i = 1000; i < 2000; ++i)
         for (int j = 1000; j < 2000; ++j)
-        assert((testComparisons6(
+        assert((testComparisons(
             year_month{year{i}, std::chrono::January},
             year_month{year{j}, std::chrono::January},
             i == j, i < j )));

diff  --git a/libcxx/test/std/time/time.cal/time.cal.ymd/time.cal.ymd.nonmembers/comparisons.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.ymd/time.cal.ymd.nonmembers/comparisons.pass.cpp
index 287dc3a33924f..d8bca7a6fbf31 100644
--- a/libcxx/test/std/time/time.cal/time.cal.ymd/time.cal.ymd.nonmembers/comparisons.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.ymd/time.cal.ymd.nonmembers/comparisons.pass.cpp
@@ -36,56 +36,56 @@ int main(int, char**)
     using month      = std::chrono::month;
     using year_month_day = std::chrono::year_month_day;
 
-    AssertComparisons6AreNoexcept<year_month_day>();
-    AssertComparisons6ReturnBool<year_month_day>();
+    AssertComparisonsAreNoexcept<year_month_day>();
+    AssertComparisonsReturnBool<year_month_day>();
 
     constexpr month January = std::chrono::January;
     constexpr month February = std::chrono::February;
 
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month_day{year{1234}, January, day{1}},
         year_month_day{year{1234}, January, day{1}},
         true, false), "");
 
     // 
diff erent day
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month_day{year{1234}, January, day{1}},
         year_month_day{year{1234}, January, day{2}},
         false, true), "");
 
     // 
diff erent month
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month_day{year{1234}, January, day{1}},
         year_month_day{year{1234}, February, day{1}},
         false, true), "");
 
     // 
diff erent year
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month_day{year{1234}, January, day{1}},
         year_month_day{year{1235}, January, day{1}},
         false, true), "");
 
 
     // 
diff erent month and day
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month_day{year{1234}, January, day{2}},
         year_month_day{year{1234}, February, day{1}},
         false, true), "");
 
     // 
diff erent year and month
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month_day{year{1234}, February, day{1}},
         year_month_day{year{1235}, January, day{1}},
         false, true), "");
 
     // 
diff erent year and day
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month_day{year{1234}, January, day{2}},
         year_month_day{year{1235}, January, day{1}},
         false, true), "");
 
     // 
diff erent year, month and day
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month_day{year{1234}, February, day{2}},
         year_month_day{year{1235}, January, day{1}},
         false, true), "");
@@ -94,7 +94,7 @@ int main(int, char**)
     // same year, 
diff erent days
     for (unsigned i = 1; i < 28; ++i)
         for (unsigned j = 1; j < 28; ++j)
-            assert((testComparisons6(
+            assert((testComparisons(
                 year_month_day{year{1234}, January, day{i}},
                 year_month_day{year{1234}, January, day{j}},
                 i == j, i < j )));
@@ -102,7 +102,7 @@ int main(int, char**)
     // same year, 
diff erent months
     for (unsigned i = 1; i < 12; ++i)
         for (unsigned j = 1; j < 12; ++j)
-            assert((testComparisons6(
+            assert((testComparisons(
                 year_month_day{year{1234}, month{i}, day{12}},
                 year_month_day{year{1234}, month{j}, day{12}},
                 i == j, i < j )));
@@ -110,7 +110,7 @@ int main(int, char**)
     // same month, 
diff erent years
     for (int i = 1000; i < 2000; ++i)
         for (int j = 1000; j < 2000; ++j)
-        assert((testComparisons6(
+        assert((testComparisons(
             year_month_day{year{i}, January, day{12}},
             year_month_day{year{j}, January, day{12}},
             i == j, i < j )));

diff  --git a/libcxx/test/std/time/time.cal/time.cal.ymdlast/time.cal.ymdlast.nonmembers/comparisons.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.ymdlast/time.cal.ymdlast.nonmembers/comparisons.pass.cpp
index 54b470750ec64..45d7e51fbe718 100644
--- a/libcxx/test/std/time/time.cal/time.cal.ymdlast/time.cal.ymdlast.nonmembers/comparisons.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.ymdlast/time.cal.ymdlast.nonmembers/comparisons.pass.cpp
@@ -33,37 +33,37 @@ int main(int, char**)
     using month_day_last      = std::chrono::month_day_last;
     using year_month_day_last = std::chrono::year_month_day_last;
 
-    AssertComparisons6AreNoexcept<year_month_day_last>();
-    AssertComparisons6ReturnBool<year_month_day_last>();
+    AssertComparisonsAreNoexcept<year_month_day_last>();
+    AssertComparisonsReturnBool<year_month_day_last>();
 
     constexpr month January = std::chrono::January;
     constexpr month February = std::chrono::February;
 
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month_day_last{year{1234}, month_day_last{January}},
         year_month_day_last{year{1234}, month_day_last{January}},
         true, false), "");
 
     // 
diff erent month
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month_day_last{year{1234}, month_day_last{January}},
         year_month_day_last{year{1234}, month_day_last{February}},
         false, true), "");
 
     // 
diff erent year
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month_day_last{year{1234}, month_day_last{January}},
         year_month_day_last{year{1235}, month_day_last{January}},
         false, true), "");
 
     // 
diff erent month
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month_day_last{year{1234}, month_day_last{January}},
         year_month_day_last{year{1234}, month_day_last{February}},
         false, true), "");
 
     // 
diff erent year and month
-    static_assert( testComparisons6(
+    static_assert( testComparisons(
         year_month_day_last{year{1234}, month_day_last{February}},
         year_month_day_last{year{1235}, month_day_last{January}},
         false, true), "");
@@ -71,7 +71,7 @@ int main(int, char**)
     // same year, 
diff erent months
     for (unsigned i = 1; i < 12; ++i)
         for (unsigned j = 1; j < 12; ++j)
-            assert((testComparisons6(
+            assert((testComparisons(
                 year_month_day_last{year{1234}, month_day_last{month{i}}},
                 year_month_day_last{year{1234}, month_day_last{month{j}}},
                 i == j, i < j )));
@@ -79,7 +79,7 @@ int main(int, char**)
     // same month, 
diff erent years
     for (int i = 1000; i < 2000; ++i)
         for (int j = 1000; j < 2000; ++j)
-        assert((testComparisons6(
+        assert((testComparisons(
             year_month_day_last{year{i}, month_day_last{January}},
             year_month_day_last{year{j}, month_day_last{January}},
             i == j, i < j )));

diff  --git a/libcxx/test/std/time/time.cal/time.cal.ymwd/time.cal.ymwd.nonmembers/comparisons.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.ymwd/time.cal.ymwd.nonmembers/comparisons.pass.cpp
index be0a84cae535e..5949dc7c900ea 100644
--- a/libcxx/test/std/time/time.cal/time.cal.ymwd/time.cal.ymwd.nonmembers/comparisons.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.ymwd/time.cal.ymwd.nonmembers/comparisons.pass.cpp
@@ -30,57 +30,57 @@ int main(int, char**)
     using weekday            = std::chrono::weekday;
     using year_month_weekday = std::chrono::year_month_weekday;
 
-    AssertComparisons2AreNoexcept<year_month_weekday>();
-    AssertComparisons2ReturnBool<year_month_weekday>();
+    AssertEqualityAreNoexcept<year_month_weekday>();
+    AssertEqualityReturnBool<year_month_weekday>();
 
     constexpr month January   = std::chrono::January;
     constexpr month February  = std::chrono::February;
     constexpr weekday Tuesday = std::chrono::Tuesday;
 
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday{year{1234}, January, weekday_indexed{Tuesday, 1}},
         year_month_weekday{year{1234}, January, weekday_indexed{Tuesday, 1}},
         true), "");
 
     // 
diff erent day
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday{year{1234}, January, weekday_indexed{Tuesday, 1}},
         year_month_weekday{year{1234}, January, weekday_indexed{Tuesday, 2}},
         false), "");
 
     // 
diff erent month
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday{year{1234}, January,  weekday_indexed{Tuesday, 1}},
         year_month_weekday{year{1234}, February, weekday_indexed{Tuesday, 1}},
         false), "");
 
     // 
diff erent year
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday{year{1234}, January, weekday_indexed{Tuesday, 1}},
         year_month_weekday{year{1235}, January, weekday_indexed{Tuesday, 1}},
         false), "");
 
 
     // 
diff erent month and day
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday{year{1234}, January,  weekday_indexed{Tuesday, 1}},
         year_month_weekday{year{1234}, February, weekday_indexed{Tuesday, 2}},
         false), "");
 
     // 
diff erent year and month
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday{year{1234}, February, weekday_indexed{Tuesday, 1}},
         year_month_weekday{year{1235}, January,  weekday_indexed{Tuesday, 1}},
         false), "");
 
     // 
diff erent year and day
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday{year{1234}, January, weekday_indexed{Tuesday, 2}},
         year_month_weekday{year{1235}, January, weekday_indexed{Tuesday, 1}},
         false), "");
 
     // 
diff erent year, month and day
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday{year{1234}, February, weekday_indexed{Tuesday, 2}},
         year_month_weekday{year{1235}, January,  weekday_indexed{Tuesday, 1}},
         false), "");
@@ -89,7 +89,7 @@ int main(int, char**)
     // same year, 
diff erent days
     for (unsigned i = 1; i < 28; ++i)
         for (unsigned j = 1; j < 28; ++j)
-            assert((testComparisons2(
+            assert((testEquality(
                 year_month_weekday{year{1234}, January, weekday_indexed{Tuesday, i}},
                 year_month_weekday{year{1234}, January, weekday_indexed{Tuesday, j}},
                 i == j)));
@@ -97,7 +97,7 @@ int main(int, char**)
     // same year, 
diff erent months
     for (unsigned i = 1; i < 12; ++i)
         for (unsigned j = 1; j < 12; ++j)
-            assert((testComparisons2(
+            assert((testEquality(
                 year_month_weekday{year{1234}, month{i}, weekday_indexed{Tuesday, 1}},
                 year_month_weekday{year{1234}, month{j}, weekday_indexed{Tuesday, 1}},
                 i == j)));
@@ -105,7 +105,7 @@ int main(int, char**)
     // same month, 
diff erent years
     for (int i = 1000; i < 2000; ++i)
         for (int j = 1000; j < 2000; ++j)
-        assert((testComparisons2(
+        assert((testEquality(
             year_month_weekday{year{i}, January, weekday_indexed{Tuesday, 1}},
             year_month_weekday{year{j}, January, weekday_indexed{Tuesday, 1}},
             i == j)));

diff  --git a/libcxx/test/std/time/time.cal/time.cal.ymwdlast/time.cal.ymwdlast.nonmembers/comparisons.pass.cpp b/libcxx/test/std/time/time.cal/time.cal.ymwdlast/time.cal.ymwdlast.nonmembers/comparisons.pass.cpp
index 5c008c76b21d2..6f6ab4305f5ba 100644
--- a/libcxx/test/std/time/time.cal/time.cal.ymwdlast/time.cal.ymwdlast.nonmembers/comparisons.pass.cpp
+++ b/libcxx/test/std/time/time.cal/time.cal.ymwdlast/time.cal.ymwdlast.nonmembers/comparisons.pass.cpp
@@ -30,58 +30,58 @@ int main(int, char**)
     using weekday_last            = std::chrono::weekday_last;
     using year_month_weekday_last = std::chrono::year_month_weekday_last;
 
-    AssertComparisons2AreNoexcept<year_month_weekday_last>();
-    AssertComparisons2ReturnBool<year_month_weekday_last>();
+    AssertEqualityAreNoexcept<year_month_weekday_last>();
+    AssertEqualityReturnBool<year_month_weekday_last>();
 
     constexpr month January   = std::chrono::January;
     constexpr month February  = std::chrono::February;
     constexpr weekday Tuesday = std::chrono::Tuesday;
     constexpr weekday Wednesday = std::chrono::Wednesday;
 
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday_last{year{1234}, January, weekday_last{Tuesday}},
         year_month_weekday_last{year{1234}, January, weekday_last{Tuesday}},
         true), "");
 
     // 
diff erent day
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday_last{year{1234}, January, weekday_last{Tuesday}},
         year_month_weekday_last{year{1234}, January, weekday_last{Wednesday}},
         false), "");
 
     // 
diff erent month
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday_last{year{1234}, January,  weekday_last{Tuesday}},
         year_month_weekday_last{year{1234}, February, weekday_last{Tuesday}},
         false), "");
 
     // 
diff erent year
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday_last{year{1234}, January, weekday_last{Tuesday}},
         year_month_weekday_last{year{1235}, January, weekday_last{Tuesday}},
         false), "");
 
 
     // 
diff erent month and day
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday_last{year{1234}, January,  weekday_last{Tuesday}},
         year_month_weekday_last{year{1234}, February, weekday_last{Wednesday}},
         false), "");
 
     // 
diff erent year and month
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday_last{year{1234}, February, weekday_last{Tuesday}},
         year_month_weekday_last{year{1235}, January,  weekday_last{Tuesday}},
         false), "");
 
     // 
diff erent year and day
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday_last{year{1234}, January, weekday_last{Wednesday}},
         year_month_weekday_last{year{1235}, January, weekday_last{Tuesday}},
         false), "");
 
     // 
diff erent year, month and day
-    static_assert( testComparisons2(
+    static_assert( testEquality(
         year_month_weekday_last{year{1234}, February, weekday_last{Wednesday}},
         year_month_weekday_last{year{1235}, January,  weekday_last{Tuesday}},
         false), "");
@@ -90,7 +90,7 @@ int main(int, char**)
     // same year, 
diff erent days
     for (unsigned i = 1; i < 28; ++i)
         for (unsigned j = 1; j < 28; ++j)
-            assert((testComparisons2(
+            assert((testEquality(
                 year_month_weekday_last{year{1234}, January, weekday_last{weekday{i}}},
                 year_month_weekday_last{year{1234}, January, weekday_last{weekday{j}}},
                 i == j)));
@@ -98,7 +98,7 @@ int main(int, char**)
     // same year, 
diff erent months
     for (unsigned i = 1; i < 12; ++i)
         for (unsigned j = 1; j < 12; ++j)
-            assert((testComparisons2(
+            assert((testEquality(
                 year_month_weekday_last{year{1234}, month{i}, weekday_last{Tuesday}},
                 year_month_weekday_last{year{1234}, month{j}, weekday_last{Tuesday}},
                 i == j)));
@@ -106,7 +106,7 @@ int main(int, char**)
     // same month, 
diff erent years
     for (int i = 1000; i < 2000; ++i)
         for (int j = 1000; j < 2000; ++j)
-        assert((testComparisons2(
+        assert((testEquality(
             year_month_weekday_last{year{i}, January, weekday_last{Tuesday}},
             year_month_weekday_last{year{j}, January, weekday_last{Tuesday}},
             i == j)));

diff  --git a/libcxx/test/support/test_comparisons.h b/libcxx/test/support/test_comparisons.h
index 90440f4b18d61..9abded5f73f3e 100644
--- a/libcxx/test/support/test_comparisons.h
+++ b/libcxx/test/support/test_comparisons.h
@@ -7,13 +7,18 @@
 //===----------------------------------------------------------------------===//
 //  A set of routines for testing the comparison operators of a type
 //
-//      XXXX6 tests all six comparison operators
-//      XXXX2 tests only op== and op!=
+//      FooOrder<expected-ordering>  All seven comparison operators, requires C++20 or newer.
+//      FooComparison                All six pre-C++20 comparison operators
+//      FooEquality                  Equality operators operator== and operator!=
 //
-//      AssertComparisonsXAreNoexcept       static_asserts that the operations are all noexcept.
-//      AssertComparisonsXReturnBool        static_asserts that the operations return bool.
-//      AssertComparisonsXConvertibleToBool static_asserts that the operations return something convertible to bool.
-
+//      AssertXAreNoexcept           static_asserts that the operations are all noexcept.
+//      AssertXReturnBool            static_asserts that the operations return bool.
+//      AssertOrderReturn            static_asserts that the pre-C++20 comparison operations
+//                                   return bool and operator<=> returns the proper type.
+//      AssertXConvertibleToBool     static_asserts that the operations return something convertible to bool.
+//      testXValues                  returns the result of the comparison of all operations.
+//
+//      AssertOrderConvertibleToBool doesn't exist yet. It will be implemented when needed.
 
 #ifndef TEST_COMPARISONS_H
 #define TEST_COMPARISONS_H
@@ -24,7 +29,7 @@
 
 //  Test all six comparison operations for sanity
 template <class T, class U = T>
-TEST_CONSTEXPR_CXX14 bool testComparisons6(const T& t1, const U& t2, bool isEqual, bool isLess)
+TEST_CONSTEXPR_CXX14 bool testComparisons(const T& t1, const U& t2, bool isEqual, bool isLess)
 {
     assert(!(isEqual && isLess) && "isEqual and isLess cannot be both true");
     if (isEqual)
@@ -78,16 +83,16 @@ TEST_CONSTEXPR_CXX14 bool testComparisons6(const T& t1, const U& t2, bool isEqua
 
 //  Easy call when you can init from something already comparable.
 template <class T, class Param>
-TEST_CONSTEXPR_CXX14 bool testComparisons6Values(Param val1, Param val2)
+TEST_CONSTEXPR_CXX14 bool testComparisonsValues(Param val1, Param val2)
 {
     const bool isEqual = val1 == val2;
     const bool isLess  = val1  < val2;
 
-    return testComparisons6(T(val1), T(val2), isEqual, isLess);
+    return testComparisons(T(val1), T(val2), isEqual, isLess);
 }
 
 template <class T, class U = T>
-void AssertComparisons6AreNoexcept()
+void AssertComparisonsAreNoexcept()
 {
     ASSERT_NOEXCEPT(std::declval<const T&>() == std::declval<const U&>());
     ASSERT_NOEXCEPT(std::declval<const T&>() != std::declval<const U&>());
@@ -98,7 +103,7 @@ void AssertComparisons6AreNoexcept()
 }
 
 template <class T, class U = T>
-void AssertComparisons6ReturnBool()
+void AssertComparisonsReturnBool()
 {
     ASSERT_SAME_TYPE(decltype(std::declval<const T&>() == std::declval<const U&>()), bool);
     ASSERT_SAME_TYPE(decltype(std::declval<const T&>() != std::declval<const U&>()), bool);
@@ -110,7 +115,7 @@ void AssertComparisons6ReturnBool()
 
 
 template <class T, class U = T>
-void AssertComparisons6ConvertibleToBool()
+void AssertComparisonsConvertibleToBool()
 {
     static_assert((std::is_convertible<decltype(std::declval<const T&>() == std::declval<const U&>()), bool>::value), "");
     static_assert((std::is_convertible<decltype(std::declval<const T&>() != std::declval<const U&>()), bool>::value), "");
@@ -120,9 +125,35 @@ void AssertComparisons6ConvertibleToBool()
     static_assert((std::is_convertible<decltype(std::declval<const T&>() >= std::declval<const U&>()), bool>::value), "");
 }
 
+#if TEST_STD_VER > 17
+template <class T, class U = T>
+void AssertOrderAreNoexcept() {
+  AssertComparisonsAreNoexcept<T, U>();
+  ASSERT_NOEXCEPT(std::declval<const T&>() <=> std::declval<const U&>());
+}
+
+template <class Order, class T, class U = T>
+void AssertOrderReturn() {
+  AssertComparisonsReturnBool<T, U>();
+  ASSERT_SAME_TYPE(decltype(std::declval<const T&>() <=> std::declval<const U&>()), Order);
+}
+
+template <class Order, class T, class U = T>
+constexpr bool testOrder(const T& t1, const U& t2, Order order) {
+  return (t1 <=> t2 == order) &&
+         testComparisons(t1, t2, order == Order::equal || order == Order::equivalent, order == Order::less);
+}
+
+template <class T, class Param>
+constexpr bool testOrderValues(Param val1, Param val2) {
+  return testOrder(T(val1), T(val2), val1 <=> val2);
+}
+
+#endif
+
 //  Test all two comparison operations for sanity
 template <class T, class U = T>
-TEST_CONSTEXPR_CXX14 bool testComparisons2(const T& t1, const U& t2, bool isEqual)
+TEST_CONSTEXPR_CXX14 bool testEquality(const T& t1, const U& t2, bool isEqual)
 {
     if (isEqual)
         {
@@ -144,22 +175,22 @@ TEST_CONSTEXPR_CXX14 bool testComparisons2(const T& t1, const U& t2, bool isEqua
 
 //  Easy call when you can init from something already comparable.
 template <class T, class Param>
-TEST_CONSTEXPR_CXX14 bool testComparisons2Values(Param val1, Param val2)
+TEST_CONSTEXPR_CXX14 bool testEqualityValues(Param val1, Param val2)
 {
     const bool isEqual = val1 == val2;
 
-    return testComparisons2(T(val1), T(val2), isEqual);
+    return testEquality(T(val1), T(val2), isEqual);
 }
 
 template <class T, class U = T>
-void AssertComparisons2AreNoexcept()
+void AssertEqualityAreNoexcept()
 {
     ASSERT_NOEXCEPT(std::declval<const T&>() == std::declval<const U&>());
     ASSERT_NOEXCEPT(std::declval<const T&>() != std::declval<const U&>());
 }
 
 template <class T, class U = T>
-void AssertComparisons2ReturnBool()
+void AssertEqualityReturnBool()
 {
     ASSERT_SAME_TYPE(decltype(std::declval<const T&>() == std::declval<const U&>()), bool);
     ASSERT_SAME_TYPE(decltype(std::declval<const T&>() != std::declval<const U&>()), bool);
@@ -167,7 +198,7 @@ void AssertComparisons2ReturnBool()
 
 
 template <class T, class U = T>
-void AssertComparisons2ConvertibleToBool()
+void AssertEqualityConvertibleToBool()
 {
     static_assert((std::is_convertible<decltype(std::declval<const T&>() == std::declval<const U&>()), bool>::value), "");
     static_assert((std::is_convertible<decltype(std::declval<const T&>() != std::declval<const U&>()), bool>::value), "");


        


More information about the libcxx-commits mailing list