summaryrefslogtreecommitdiffstats
path: root/libcxx/test
diff options
context:
space:
mode:
Diffstat (limited to 'libcxx/test')
-rw-r--r--libcxx/test/std/language.support/support.limits/support.limits.general/bit.version.pass.cpp20
-rw-r--r--libcxx/test/std/language.support/support.limits/support.limits.general/version.version.pass.cpp20
2 files changed, 40 insertions, 0 deletions
diff --git a/libcxx/test/std/language.support/support.limits/support.limits.general/bit.version.pass.cpp b/libcxx/test/std/language.support/support.limits/support.limits.general/bit.version.pass.cpp
index 3e42d06fbe8..4f99d8d86a7 100644
--- a/libcxx/test/std/language.support/support.limits/support.limits.general/bit.version.pass.cpp
+++ b/libcxx/test/std/language.support/support.limits/support.limits.general/bit.version.pass.cpp
@@ -15,6 +15,7 @@
/* Constant Value
__cpp_lib_bit_cast 201806L [C++2a]
+ __cpp_lib_endian 201907L [C++2a]
*/
#include <bit>
@@ -26,18 +27,30 @@
# error "__cpp_lib_bit_cast should not be defined before c++2a"
# endif
+# ifdef __cpp_lib_endian
+# error "__cpp_lib_endian should not be defined before c++2a"
+# endif
+
#elif TEST_STD_VER == 14
# ifdef __cpp_lib_bit_cast
# error "__cpp_lib_bit_cast should not be defined before c++2a"
# endif
+# ifdef __cpp_lib_endian
+# error "__cpp_lib_endian should not be defined before c++2a"
+# endif
+
#elif TEST_STD_VER == 17
# ifdef __cpp_lib_bit_cast
# error "__cpp_lib_bit_cast should not be defined before c++2a"
# endif
+# ifdef __cpp_lib_endian
+# error "__cpp_lib_endian should not be defined before c++2a"
+# endif
+
#elif TEST_STD_VER > 17
# if !defined(_LIBCPP_VERSION)
@@ -53,6 +66,13 @@
# endif
# endif
+# ifndef __cpp_lib_endian
+# error "__cpp_lib_endian should be defined in c++2a"
+# endif
+# if __cpp_lib_endian != 201907L
+# error "__cpp_lib_endian should have the value 201907L in c++2a"
+# endif
+
#endif // TEST_STD_VER > 17
int main(int, char**) { return 0; }
diff --git a/libcxx/test/std/language.support/support.limits/support.limits.general/version.version.pass.cpp b/libcxx/test/std/language.support/support.limits/support.limits.general/version.version.pass.cpp
index 3503051afad..e721b73ed06 100644
--- a/libcxx/test/std/language.support/support.limits/support.limits.general/version.version.pass.cpp
+++ b/libcxx/test/std/language.support/support.limits/support.limits.general/version.version.pass.cpp
@@ -37,6 +37,7 @@
__cpp_lib_constexpr_swap_algorithms 201806L [C++2a]
__cpp_lib_destroying_delete 201806L [C++2a]
__cpp_lib_enable_shared_from_this 201603L [C++17]
+ __cpp_lib_endian 201907L [C++2a]
__cpp_lib_erase_if 201811L [C++2a]
__cpp_lib_exchange_function 201304L [C++14]
__cpp_lib_execution 201603L [C++17]
@@ -197,6 +198,10 @@
# error "__cpp_lib_enable_shared_from_this should not be defined before c++17"
# endif
+# ifdef __cpp_lib_endian
+# error "__cpp_lib_endian should not be defined before c++2a"
+# endif
+
# ifdef __cpp_lib_erase_if
# error "__cpp_lib_erase_if should not be defined before c++2a"
# endif
@@ -537,6 +542,10 @@
# error "__cpp_lib_enable_shared_from_this should not be defined before c++17"
# endif
+# ifdef __cpp_lib_endian
+# error "__cpp_lib_endian should not be defined before c++2a"
+# endif
+
# ifdef __cpp_lib_erase_if
# error "__cpp_lib_erase_if should not be defined before c++2a"
# endif
@@ -994,6 +1003,10 @@
# error "__cpp_lib_enable_shared_from_this should have the value 201603L in c++17"
# endif
+# ifdef __cpp_lib_endian
+# error "__cpp_lib_endian should not be defined before c++2a"
+# endif
+
# ifdef __cpp_lib_erase_if
# error "__cpp_lib_erase_if should not be defined before c++2a"
# endif
@@ -1682,6 +1695,13 @@
# error "__cpp_lib_enable_shared_from_this should have the value 201603L in c++2a"
# endif
+# ifndef __cpp_lib_endian
+# error "__cpp_lib_endian should be defined in c++2a"
+# endif
+# if __cpp_lib_endian != 201907L
+# error "__cpp_lib_endian should have the value 201907L in c++2a"
+# endif
+
# ifndef __cpp_lib_erase_if
# error "__cpp_lib_erase_if should be defined in c++2a"
# endif
OpenPOWER on IntegriCloud