mirror of
https://github.com/boostorg/smart_ptr.git
synced 2025-07-29 12:27:14 +02:00
@ -25,17 +25,6 @@ namespace detail
|
||||
|
||||
#if !defined( BOOST_NO_CXX11_RVALUE_REFERENCES )
|
||||
|
||||
#if defined( __GNUC__ ) && __GNUC__ * 100 + __GNUC_MINOR__ <= 404
|
||||
|
||||
// GCC 4.4 supports an outdated version of rvalue references and creates a copy of the forwarded object.
|
||||
// This results in warnings 'returning reference to temporary'. Therefore we use a special version similar to std::forward.
|
||||
template< class T > T&& sp_forward( T && t ) BOOST_NOEXCEPT
|
||||
{
|
||||
return t;
|
||||
}
|
||||
|
||||
#else
|
||||
|
||||
template< class T > T&& sp_forward( T & t ) BOOST_NOEXCEPT
|
||||
{
|
||||
return static_cast< T&& >( t );
|
||||
@ -43,8 +32,6 @@ template< class T > T&& sp_forward( T & t ) BOOST_NOEXCEPT
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
} // namespace detail
|
||||
|
||||
} // namespace boost
|
||||
|
Reference in New Issue
Block a user