Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r56626 - branches/release/boost/numeric/ublas
From: guwi17_at_[hidden]
Date: 2009-10-06 19:47:53


Author: guwi17
Date: 2009-10-06 19:47:53 EDT (Tue, 06 Oct 2009)
New Revision: 56626
URL: http://svn.boost.org/trac/boost/changeset/56626

Log:
close #3293 (resized identity matrix)
 * merged [56163] into release

Properties modified:
   branches/release/boost/numeric/ublas/ (props changed)
Text files modified:
   branches/release/boost/numeric/ublas/matrix.hpp | 4 ++++
   1 files changed, 4 insertions(+), 0 deletions(-)

Modified: branches/release/boost/numeric/ublas/matrix.hpp
==============================================================================
--- branches/release/boost/numeric/ublas/matrix.hpp (original)
+++ branches/release/boost/numeric/ublas/matrix.hpp 2009-10-06 19:47:53 EDT (Tue, 06 Oct 2009)
@@ -2466,11 +2466,13 @@
         void resize (size_type size, bool preserve = true) {
             size1_ = size;
             size2_ = size;
+ size_common_ = ((std::min)(size1_, size2_));
         }
         BOOST_UBLAS_INLINE
         void resize (size_type size1, size_type size2, bool /*preserve*/ = true) {
             size1_ = size1;
             size2_ = size2;
+ size_common_ = ((std::min)(size1_, size2_));
         }
 
         // Element access
@@ -2487,6 +2489,7 @@
         identity_matrix &operator = (const identity_matrix &m) {
             size1_ = m.size1_;
             size2_ = m.size2_;
+ size_common_ = m.size_common_;
             return *this;
         }
         BOOST_UBLAS_INLINE
@@ -2501,6 +2504,7 @@
             if (this != &m) {
                 std::swap (size1_, m.size1_);
                 std::swap (size2_, m.size2_);
+ std::swap (size_common_, m.size_common_);
             }
         }
         BOOST_UBLAS_INLINE


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk