Re: [Boost-bugs] [Boost C++ Libraries] #1045: [multi_array] Need a proper swap operation

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #1045: [multi_array] Need a proper swap operation
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2010-12-02 18:24:17


#1045: [multi_array] Need a proper swap operation
---------------------------------------------+------------------------------
  Reporter: Marcus Lindblom <macke@…> | Owner: garcia
      Type: Feature Requests | Status: new
 Milestone: To Be Determined | Component: multi_array
   Version: Boost 1.34.0 | Severity: Optimization
Resolution: | Keywords:
---------------------------------------------+------------------------------

Comment (by rhys.ulerich@…):

 Just capturing some old email to/from Ronald Garcia regarding the patch...

 {{{
 Sat, Dec 12, 2009 at 1:01 PM
 From: Ronald Garcia <garcia_at_[hidden]>
 To: Rhys Ulerich <rhys.ulerich_at_[hidden]>
 Hi Rhys,

 I have looked over your patch to multi_array. The good news is
 that on the whole I like what you are proposing. The bad news is
 that I will want to make some more fundamental changes to MultiArray
 before or at the same time as I add this functionality to the library.

 The problem right now is that swap as you propose it is not simply
 a faster-but-equivalent version of the inefficient operator=() based
 implementation of swap. However I see that more as a problem with
 operator=() as it's currently presented than a problem with your swap.
 The current implementation of multi_array and the MultiArray concept
 use operator=() to represent deep copy semantics, and I now see that
 as problematic because of the ways that C++ treats operator=() and
 constructors specially.

 Before I add swap to multi_array and multi_array_ref, I need to rename
 the functionality currently associated with operator=() and remove
 operator= from the concept. Then multi_array and multi_array_ref can
 independently support a more traditional operator=() behavior, which
 would be compatible with your swap.

 I appreciate your contribution to multi_array, and will see about getting
 other changes going, but it won't happen before the next release is
 frozen I'm afraid.

 Best,
 Ron
 }}}

 {{{
 Sat, Dec 12, 2009 at 1:09 PM
 From: Rhys Ulerich <rhys.ulerich_at_[hidden]>
 To: Ronald Garcia <garcia_at_[hidden]>
 Hi Ron,

 Thanks for looking over the patch, and no problem on holding off on
 the functionality.

 My $0.02 is that the deep copy semantics associated with operator=
 seem reasonable/natural to me in the current implementation, but I may
 be missing some nuances in the language. I'd be interested in seeing
 the upcoming changes as they develop. Do you use the boost
 development list for MultiArray discussion? Or some other list where
 I can subscribe?

 - Rhys
 }}}

 {{{
 Sun, Dec 13, 2009 at 8:08 AM
 From: Ronald Garcia <garcia_at_[hidden]>
 To: Rhys Ulerich <rhys.ulerich_at_[hidden]>
 Hi Rhys,

 Thanks for your feedback. There hasn't been a great deal of
 multi_array discussion in some time, but I will write to the
 boost developers list about these issues.

 Cheers,
 Ron
 }}}

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/1045#comment:7>
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:04 UTC