Ticket #7598: unique_ptr.3.patch
File unique_ptr.3.patch, 1.5 KB (added by , 10 years ago) |
---|
-
boost/interprocess/smart_ptr/unique_ptr.hpp
old new 82 82 class unique_ptr 83 83 { 84 84 /// @cond 85 struct nat {int for_bool_;}; 85 struct nat {int for_bool;}; 86 struct nat2 {int for_bool;}; 87 typedef int nat2::*nullptr_t; 86 88 typedef typename ipcdetail::add_reference<D>::type deleter_reference; 87 89 typedef typename ipcdetail::add_reference<const D>::type deleter_const_reference; 88 90 /// @endcond … … 175 177 //! 176 178 //!Throws: nothing. 177 179 template <class U, class E> 178 unique_ptr(BOOST_RV_REF_ 2_TEMPL_ARGS(unique_ptr, U, E)u,180 unique_ptr(BOOST_RV_REF_BEG unique_ptr<U, E> BOOST_RV_REF_END u, 179 181 typename ipcdetail::enable_if_c< 180 182 ipcdetail::is_convertible<typename unique_ptr<U, E>::pointer, pointer>::value && 181 183 ipcdetail::is_convertible<E, D>::value && … … 230 232 //! 231 233 //!Throws: nothing. 232 234 template <class U, class E> 233 unique_ptr& operator=(BOOST_RV_REF_ 2_TEMPL_ARGS(unique_ptr, U, E)u)235 unique_ptr& operator=(BOOST_RV_REF_BEG unique_ptr<U, E> BOOST_RV_REF_END u) 234 236 { 235 237 reset(u.release()); 236 238 ptr_.second() = boost::move(u.get_deleter()); … … 246 248 //!Returns: *this. 247 249 //! 248 250 //!Throws: nothing. 249 unique_ptr& operator=( int nat::*)251 unique_ptr& operator=(nullptr_t) 250 252 { 251 253 reset(); 252 254 return *this;