[libcxx-commits] [PATCH] D131372: [libc++][spaceship] Implement std::variant::operator<=>

Adrian Vogelsgesang via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Thu Aug 11 04:32:31 PDT 2022


avogelsgesang added a subscriber: philnik.
avogelsgesang added inline comments.


================
Comment at: libcxx/test/support/test_comparisons.h:97
+template <class T, class U = T>
+_LIBCPP_NODISCARD TEST_CONSTEXPR_CXX14 bool testComparisons(const T& t1, const U& t2, bool isEqual, bool isLess) {
+    bool isGreater = !isEqual && !isLess;
----------------
copying @philnik's comment from https://reviews.llvm.org/D131364:

> You shouldn't use libc++-specific macros in the tests. Instead, add a new macro to test_macros.h and use it here. Otherwise the tests that use test_comparisons.h would break for other implementations.




Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D131372/new/

https://reviews.llvm.org/D131372



More information about the libcxx-commits mailing list