[Boost-bugs] [Boost C++ Libraries] #10897: Pool allocator does not perfect forward it's argument

Subject: [Boost-bugs] [Boost C++ Libraries] #10897: Pool allocator does not perfect forward it's argument
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2014-12-24 15:17:52


#10897: Pool allocator does not perfect forward it's argument
-------------------------------+----------------------
 Reporter: bertello.matteo@… | Owner: cnewbold
     Type: Feature Requests | Status: new
Milestone: To Be Determined | Component: pool
  Version: Boost 1.58.0 | Severity: Problem
 Keywords: |
-------------------------------+----------------------
 The pool_allocator library has not been updated to C++11 yet.
 One of the greatest missing feature is the lack of perfect forwarding of
 the parameters of "conctruct" in pool_allocator and fast_pool_allocator.
 This prevent the move constructor of the allocated object to be called.
 Right now the construct implementation is as follow:

 {{{
 static void construct(const pointer ptr, const value_type & t)
 { new (ptr) T(t); }
 }}}

 while it should be:
 {{{
 template<typename ...Args>
 static void construct(const pointer ptr, Args&& ...args)
 { new (ptr) T(std::forward<Args> (args)...); }
 }}}

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/10897>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:17 UTC