[Boost-bugs] [Boost C++ Libraries] #7749: In Assignment operator, argument should be passed by reference.

Subject: [Boost-bugs] [Boost C++ Libraries] #7749: In Assignment operator, argument should be passed by reference.
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2012-11-29 05:41:45


#7749: In Assignment operator, argument should be passed by reference.
------------------------------------------------+---------------------------
 Reporter: Gaurav Gupta <g.gupta@…> | Owner: joaquin
     Type: Bugs | Status: new
Milestone: To Be Determined | Component: multi_index
  Version: Boost 1.52.0 | Severity: Problem
 Keywords: |
------------------------------------------------+---------------------------
 In file boost/multi_index_container.hpp
 When defining the assignment operator, argument is not passed by
 reference.


 {{{
 multi_index_container<Value,IndexSpecifierList,Allocator>& operator=(
     multi_index_container<Value,IndexSpecifierList,Allocator> x)
   {
     BOOST_MULTI_INDEX_CHECK_INVARIANT;
     this->swap(x);
     return *this;
   }

 }}}

 Attached patch is fix for it.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/7749>
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:50:11 UTC