Implement LWG#2385; remove the allocator-aware std::function::assign call. It was useless, and didn't actually *do anything* with the allocator. Now it's gone. On the off chance that someone is mistakenly calling it, it's only gone in C++1z
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@258697 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -407,7 +407,7 @@ public:
|
||||
// function modifiers:
|
||||
void swap(function&) noexcept;
|
||||
template<class F, class Alloc>
|
||||
void assign(F&&, const Alloc&);
|
||||
void assign(F&&, const Alloc&); // Removed in C++17
|
||||
|
||||
// function capacity:
|
||||
explicit operator bool() const noexcept;
|
||||
@@ -1626,10 +1626,13 @@ public:
|
||||
|
||||
// function modifiers:
|
||||
void swap(function&) _NOEXCEPT;
|
||||
|
||||
#if _LIBCPP_STD_VER <= 14
|
||||
template<class _Fp, class _Alloc>
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
void assign(_Fp&& __f, const _Alloc& __a)
|
||||
{function(allocator_arg, __a, _VSTD::forward<_Fp>(__f)).swap(*this);}
|
||||
#endif
|
||||
|
||||
// function capacity:
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
|
||||
Reference in New Issue
Block a user