[Boost-bugs] [Boost C++ Libraries] #2836: Request boost::optional<T>::optional_assign_to, optional_move_to, optional_swap

Subject: [Boost-bugs] [Boost C++ Libraries] #2836: Request boost::optional<T>::optional_assign_to, optional_move_to, optional_swap
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2009-03-07 11:25:11


#2836: Request boost::optional<T>::optional_assign_to, optional_move_to,
optional_swap
-------------------------------------+--------------------------------------
 Reporter: aschoedl_at_[hidden] | Owner: nielsdekker
     Type: Feature Requests | Status: new
Milestone: Boost 1.39.0 | Component: optional
  Version: Boost 1.38.0 | Severity: Optimization
 Keywords: optional assign |
-------------------------------------+--------------------------------------
 I request the three member functions

 template< class U > bool boost::optional<T>::optional_assign_to(U& t)
 const;
 template< class U > bool boost::optional<T>::optional_move_to(U& t);
 bool boost::optional<T>::optional_swap(T& t);

 which, if !*this, return false, and otherwise return true and are
 equivalent to

 t=**this;
 t=**this; and *this may have any value after the move
 std::swap( t, **this );

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/2836>
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:49:59 UTC