diff --git a/include/turtle/detail/action.hpp b/include/turtle/detail/action.hpp index 8c49633..ed055d2 100644 --- a/include/turtle/detail/action.hpp +++ b/include/turtle/detail/action.hpp @@ -109,11 +109,17 @@ namespace detail { this->set( boost::bind( - &boost::move< BOOST_RV_REF(Value) >, + &move< Value >, boost::ref( store( boost::move( v ) ) ) ) ); } private: + template< typename T > + static T&& move( T& t ) + { + return std::move( t ); + } + struct value : boost::noncopyable { virtual ~value() diff --git a/include/turtle/detail/function_impl_template.hpp b/include/turtle/detail/function_impl_template.hpp index 4e322db..4d47a82 100644 --- a/include/turtle/detail/function_impl_template.hpp +++ b/include/turtle/detail/function_impl_template.hpp @@ -183,9 +183,9 @@ namespace detail this->e_->throws( t ); } template< typename TT > - void moves( TT t ) + void moves( BOOST_RV_REF(TT) t ) { - this->e_->moves( t ); + this->e_->moves( boost::move( t ) ); } lock lock_;