From 859bf40761b31a687d575d2ae463b20ee7e7c2d7 Mon Sep 17 00:00:00 2001 From: Marshall Clow Date: Tue, 20 Nov 2018 20:37:07 +0000 Subject: [PATCH] Mark P0771 as complete; we already did this - I just added tests to be sure llvm-svn: 347343 --- .../func.wrap.func.con/copy_move.pass.cpp | 14 +++++++++++++- libcxx/www/cxx2a_status.html | 4 ++-- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/libcxx/test/std/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/copy_move.pass.cpp b/libcxx/test/std/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/copy_move.pass.cpp index faf4f11573d1..e9b399a2edd2 100644 --- a/libcxx/test/std/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/copy_move.pass.cpp +++ b/libcxx/test/std/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/copy_move.pass.cpp @@ -12,7 +12,7 @@ // class function // function(const function& f); -// function(function&& f); +// function(function&& f); // noexcept in C++20 #include #include @@ -109,6 +109,10 @@ int main() assert(globalMemCounter.checkOutstandingNewEq(1)); assert(f.target()); assert(f.target() == 0); + LIBCPP_ASSERT_NOEXCEPT(std::function(std::move(f))); +#if TEST_STD_VER > 17 + ASSERT_NOEXCEPT(std::function(std::move(f))); +#endif std::function f2 = std::move(f); assert(A::count == 1); assert(globalMemCounter.checkOutstandingNewEq(1)); @@ -129,6 +133,10 @@ int main() assert(A::count == 1); assert(f.target() == nullptr); assert(f.target()); + LIBCPP_ASSERT_NOEXCEPT(std::function(std::move(f))); +#if TEST_STD_VER > 17 + ASSERT_NOEXCEPT(std::function(std::move(f))); +#endif std::function f2(std::move(f)); assert(A::count == 1); assert(f2.target() == nullptr); @@ -144,6 +152,10 @@ int main() std::function f(p); assert(f.target() == nullptr); assert(f.target()); + LIBCPP_ASSERT_NOEXCEPT(std::function(std::move(f))); +#if TEST_STD_VER > 17 + ASSERT_NOEXCEPT(std::function(std::move(f))); +#endif std::function f2(std::move(f)); assert(f2.target() == nullptr); assert(f2.target()); diff --git a/libcxx/www/cxx2a_status.html b/libcxx/www/cxx2a_status.html index a9a376f5934a..923e74e595dc 100644 --- a/libcxx/www/cxx2a_status.html +++ b/libcxx/www/cxx2a_status.html @@ -118,7 +118,7 @@ P0602R4LWGvariant and optional should propagate copy/move trivialitySan Diego P0608R3LWGA sane variant converting constructorSan Diego P0655R1LWGvisit<R>: Explicit Return Type for visitSan Diego - P0771R1LWGstd::function move constructor should be noexceptSan Diego + P0771R1LWGstd::function move constructor should be noexceptSan DiegoComplete6.0 P0896R4LWGThe One Ranges ProposalSan Diego P0899R1LWGP0899R1 - LWG 3016 is not a defectSan Diego P0919R3LWGHeterogeneous lookup for unordered containersSan Diego @@ -291,7 +291,7 @@ -

Last Updated: 12-Nov-2018

+

Last Updated: 18-Nov-2018