Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r67620 - trunk/boost/signals2
From: fmhess_at_[hidden]
Date: 2011-01-03 12:00:29


Author: fmhess
Date: 2011-01-03 12:00:26 EST (Mon, 03 Jan 2011)
New Revision: 67620
URL: http://svn.boost.org/trac/boost/changeset/67620

Log:
Use std::forward instead our own implementation.

Text files modified:
   trunk/boost/signals2/deconstruct.hpp | 14 +++-----------
   1 files changed, 3 insertions(+), 11 deletions(-)

Modified: trunk/boost/signals2/deconstruct.hpp
==============================================================================
--- trunk/boost/signals2/deconstruct.hpp (original)
+++ trunk/boost/signals2/deconstruct.hpp 2011-01-03 12:00:26 EST (Mon, 03 Jan 2011)
@@ -43,14 +43,6 @@
 
 namespace detail
 {
-
-#if !defined(BOOST_NO_RVALUE_REFERENCES)
- template< class T > T&& forward( T & t )
- {
- return static_cast< T&& >( t );
- }
-#endif
-
   inline void adl_predestruct(...) {}
 } // namespace detail
 
@@ -78,7 +70,7 @@
         if(!_postconstructed)
         {
             adl_postconstruct(_sp, const_cast<typename boost::remove_const<T>::type *>(_sp.get()),
- detail::forward<Args>(args)...);
+ std::forward<Args>(args)...);
             _postconstructed = true;
         }
         return _sp;
@@ -305,7 +297,7 @@
 
         void * pv = pd->address();
 
- new( pv ) T( detail::forward<Args>( args )... );
+ new( pv ) T( std::forward<Args>( args )... );
         pd->set_initialized();
 
         boost::shared_ptr< T > retval( pt, static_cast< T* >( pv ) );
@@ -486,7 +478,7 @@
 
 template< class T, class... Args > postconstructor_invoker< T > deconstruct( Args && ... args )
 {
- return deconstruct_access::deconstruct<T>( detail::forward<Args>( args )... );
+ return deconstruct_access::deconstruct<T>( std::forward<Args>( args )... );
 }
 
 #else


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk