diff options
| author | Asiri Rathnayake <asiri.rathnayake@arm.com> | 2016-10-06 11:15:41 +0000 |
|---|---|---|
| committer | Asiri Rathnayake <asiri.rathnayake@arm.com> | 2016-10-06 11:15:41 +0000 |
| commit | 08eb2148ffe8b627c83a3a14ac24d1dd4e418690 (patch) | |
| tree | 15364e3a90bdffc0ab52373efa8a5849dd997296 /libcxx/test/std/thread/futures/futures.promise/move_ctor.pass.cpp | |
| parent | 47faf3be89e303ee8ca4029e8b1cf4f5ea969217 (diff) | |
| download | bcm5719-llvm-08eb2148ffe8b627c83a3a14ac24d1dd4e418690.tar.gz bcm5719-llvm-08eb2148ffe8b627c83a3a14ac24d1dd4e418690.zip | |
[libcxx] Recover no-exceptions XFAILs - I
First batch of changes to get some of these XFAILs working in the
no-exceptions libc++ variant.
Changed some XFAILs to UNSUPPORTED where the test is all about exception
handling. In other cases, used the test macros TEST_THROW and
TEST_HAS_NO_EXCEPTIONS to conditionally exclude those parts of the test
that concerns exception handling behaviour.
Reviewers: EricWF, mclow.lists
Differential revision: https://reviews.llvm.org/D24562
llvm-svn: 283441
Diffstat (limited to 'libcxx/test/std/thread/futures/futures.promise/move_ctor.pass.cpp')
| -rw-r--r-- | libcxx/test/std/thread/futures/futures.promise/move_ctor.pass.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/libcxx/test/std/thread/futures/futures.promise/move_ctor.pass.cpp b/libcxx/test/std/thread/futures/futures.promise/move_ctor.pass.cpp index 9a68b5c1b4e..c9971b0a3f0 100644 --- a/libcxx/test/std/thread/futures/futures.promise/move_ctor.pass.cpp +++ b/libcxx/test/std/thread/futures/futures.promise/move_ctor.pass.cpp @@ -7,7 +7,6 @@ // //===----------------------------------------------------------------------===// // -// XFAIL: libcpp-no-exceptions // UNSUPPORTED: libcpp-has-no-threads // UNSUPPORTED: c++98, c++03 @@ -20,6 +19,7 @@ #include <future> #include <cassert> +#include "test_macros.h" #include "test_allocator.h" int main() @@ -32,6 +32,7 @@ int main() std::future<int> f = p.get_future(); assert(test_alloc_base::alloc_count == 1); assert(f.valid()); +#ifndef TEST_HAS_NO_EXCEPTIONS try { f = p0.get_future(); @@ -42,6 +43,7 @@ int main() assert(e.code() == make_error_code(std::future_errc::no_state)); } assert(test_alloc_base::alloc_count == 1); +#endif } assert(test_alloc_base::alloc_count == 0); { @@ -51,6 +53,7 @@ int main() std::future<int&> f = p.get_future(); assert(test_alloc_base::alloc_count == 1); assert(f.valid()); +#ifndef TEST_HAS_NO_EXCEPTIONS try { f = p0.get_future(); @@ -61,6 +64,7 @@ int main() assert(e.code() == make_error_code(std::future_errc::no_state)); } assert(test_alloc_base::alloc_count == 1); +#endif } assert(test_alloc_base::alloc_count == 0); { @@ -70,6 +74,7 @@ int main() std::future<void> f = p.get_future(); assert(test_alloc_base::alloc_count == 1); assert(f.valid()); +#ifndef TEST_HAS_NO_EXCEPTIONS try { f = p0.get_future(); @@ -80,6 +85,7 @@ int main() assert(e.code() == make_error_code(std::future_errc::no_state)); } assert(test_alloc_base::alloc_count == 1); +#endif } assert(test_alloc_base::alloc_count == 0); } |

