[libcxx-commits] [libcxx] a1a30dc - [libcxx][test] Test code should inspect `TEST_STD_VER`, not `_LIBCPP_STD_VER`.
Casey Carter via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Aug 2 12:07:37 PDT 2022
Author: Casey Carter
Date: 2022-08-02T12:07:29-07:00
New Revision: a1a30dc933b928a7a8277d5b5f7bd25670e68884
URL: https://github.com/llvm/llvm-project/commit/a1a30dc933b928a7a8277d5b5f7bd25670e68884
DIFF: https://github.com/llvm/llvm-project/commit/a1a30dc933b928a7a8277d5b5f7bd25670e68884.diff
LOG: [libcxx][test] Test code should inspect `TEST_STD_VER`, not `_LIBCPP_STD_VER`.
Added:
Modified:
libcxx/test/support/test_iterators.h
libcxx/test/support/test_range.h
Removed:
################################################################################
diff --git a/libcxx/test/support/test_iterators.h b/libcxx/test/support/test_iterators.h
index b98c35b1d0c6d..f7eee4ca3abfc 100644
--- a/libcxx/test/support/test_iterators.h
+++ b/libcxx/test/support/test_iterators.h
@@ -53,7 +53,7 @@ class cpp17_output_iterator
template <class T>
void operator,(T const &) = delete;
};
-#if _LIBCPP_STD_VER > 17
+#if TEST_STD_VER > 17
static_assert(std::output_iterator<cpp17_output_iterator<int*>, int>);
#endif
@@ -94,7 +94,7 @@ class cpp17_input_iterator
template <class T>
void operator,(T const &) = delete;
};
-#if _LIBCPP_STD_VER > 17
+#if TEST_STD_VER > 17
static_assert(std::input_iterator<cpp17_input_iterator<int*>>);
#endif
diff --git a/libcxx/test/support/test_range.h b/libcxx/test/support/test_range.h
index 93fe95547e941..c1cfb9ea88929 100644
--- a/libcxx/test/support/test_range.h
+++ b/libcxx/test/support/test_range.h
@@ -13,7 +13,7 @@
#include "test_iterators.h"
-#if _LIBCPP_STD_VER < 17
+#if TEST_STD_VER < 17
#error "test/support/test_range.h" can only be included in builds supporting ranges
#endif
More information about the libcxx-commits
mailing list