aboutsummaryrefslogtreecommitdiff
path: root/libcxx/test
diff options
context:
space:
mode:
authorMarshall Clow <mclow.lists@gmail.com>2019-01-07 16:17:52 +0000
committerMarshall Clow <mclow.lists@gmail.com>2019-01-07 16:17:52 +0000
commit4d4213f69449f1f6c1a1890746b330727b57cad9 (patch)
tree911c26811b0cf816dd4cd510c73ed0feb8a2cc2e /libcxx/test
parent4d7e47a5451d8debd575fdc1594f85bc869b4a2e (diff)
Add the feature test macros that were defined in p1353r0 to the headers of the appropriate tests. No actual tests yet, so NFC.
llvm-svn: 350535
Diffstat (limited to 'libcxx/test')
-rw-r--r--libcxx/test/std/language.support/support.limits/support.limits.general/compare.version.pass.cpp32
-rw-r--r--libcxx/test/std/language.support/support.limits/support.limits.general/new.version.pass.cpp2
-rw-r--r--libcxx/test/std/language.support/support.limits/support.limits.general/version.version.pass.cpp2
3 files changed, 35 insertions, 1 deletions
diff --git a/libcxx/test/std/language.support/support.limits/support.limits.general/compare.version.pass.cpp b/libcxx/test/std/language.support/support.limits/support.limits.general/compare.version.pass.cpp
new file mode 100644
index 000000000000..eff2cb293e41
--- /dev/null
+++ b/libcxx/test/std/language.support/support.limits/support.limits.general/compare.version.pass.cpp
@@ -0,0 +1,32 @@
+//===----------------------------------------------------------------------===//
+//
+// The LLVM Compiler Infrastructure
+//
+// This file is dual licensed under the MIT and the University of Illinois Open
+// Source Licenses. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+//
+// <new> feature macros
+
+/* Constant Value
+ __cpp_lib_three_way_comparison 201711L
+
+*/
+
+#include <compare>
+#include <cassert>
+#include "test_macros.h"
+
+int main()
+{
+// ensure that the macros that are supposed to be defined in <compare> are defined.
+
+/*
+#if !defined(__cpp_lib_fooby)
+# error "__cpp_lib_fooby is not defined"
+#elif __cpp_lib_fooby < 201606L
+# error "__cpp_lib_fooby has an invalid value"
+#endif
+*/
+}
diff --git a/libcxx/test/std/language.support/support.limits/support.limits.general/new.version.pass.cpp b/libcxx/test/std/language.support/support.limits/support.limits.general/new.version.pass.cpp
index 856bd8b0135e..6bcd242d1778 100644
--- a/libcxx/test/std/language.support/support.limits/support.limits.general/new.version.pass.cpp
+++ b/libcxx/test/std/language.support/support.limits/support.limits.general/new.version.pass.cpp
@@ -1,4 +1,3 @@
-
//===----------------------------------------------------------------------===//
//
// The LLVM Compiler Infrastructure
@@ -11,6 +10,7 @@
// <new> feature macros
/* Constant Value
+ __cpp_lib_destroying_delete 201806L
__cpp_lib_hardware_interference_size 201703L
__cpp_lib_launder 201606L
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 e2179e08a83c..29fe4b298907 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
@@ -29,6 +29,7 @@
__cpp_lib_complex_udls 201309L
__cpp_lib_concepts 201806L
__cpp_lib_constexpr_swap_algorithms 201806L
+ __cpp_lib_destroying_delete 201806L
__cpp_lib_enable_shared_from_this 201603L
__cpp_lib_exchange_function 201304L
__cpp_lib_execution 201603L
@@ -75,6 +76,7 @@
__cpp_lib_string_udls 201304L
__cpp_lib_string_view 201606L
__cpp_lib_to_chars 201611L
+ __cpp_lib_three_way_comparison 201711L
__cpp_lib_transformation_trait_aliases 201304L
__cpp_lib_transparent_operators 201510L
__cpp_lib_tuple_element_t 201402L