From 07546f3b93c8ffbdac6f93d11de7040dcbce6f8c Mon Sep 17 00:00:00 2001 From: Marshall Clow Date: Tue, 30 Jun 2015 14:16:49 +0000 Subject: [PATCH] Implement LWG#2407: 'packaged_task(allocator_arg_t, const Allocator&, F&&) should neither be constrained nor explicit' git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@241068 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/future | 4 ++-- .../futures/futures.tas/futures.task.members/ctor2.fail.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/include/future b/include/future index 1474ab0b..25482c6c 100644 --- a/include/future +++ b/include/future @@ -329,7 +329,7 @@ public: template explicit packaged_task(F&& f); template - explicit packaged_task(allocator_arg_t, const Allocator& a, F&& f); + packaged_task(allocator_arg_t, const Allocator& a, F&& f); ~packaged_task(); // no copy @@ -2042,7 +2042,7 @@ public: >::type > _LIBCPP_INLINE_VISIBILITY - explicit packaged_task(allocator_arg_t, const _Allocator& __a, _Fp&& __f) + packaged_task(allocator_arg_t, const _Allocator& __a, _Fp&& __f) : __f_(allocator_arg, __a, _VSTD::forward<_Fp>(__f)), __p_(allocator_arg, __a) {} // ~packaged_task() = default; diff --git a/test/std/thread/futures/futures.tas/futures.task.members/ctor2.fail.cpp b/test/std/thread/futures/futures.tas/futures.task.members/ctor2.fail.cpp index e81adfa6..e4df4ec2 100644 --- a/test/std/thread/futures/futures.tas/futures.task.members/ctor2.fail.cpp +++ b/test/std/thread/futures/futures.tas/futures.task.members/ctor2.fail.cpp @@ -11,7 +11,7 @@ // class packaged_task // template -// explicit packaged_task(allocator_arg_t, const Allocator& a, F&& f); +// packaged_task(allocator_arg_t, const Allocator& a, F&& f); // These constructors shall not participate in overload resolution if // decay::type is the same type as std::packaged_task.