Opened 8 years ago

#10002 new Bugs

No swap for mapped_vector::reference

Reported by: Christian Adaker <christian.adaker@…> Owned by: Gunter
Milestone: To Be Determined Component: uBLAS
Version: Boost 1.55.0 Severity: Problem
Keywords: Cc:

Description

Hi.

When compiling the following code

#include <boost/numeric/ublas/lu.hpp>
#include <boost/numeric/ublas/matrix.hpp>
#include <boost/numeric/ublas/vector_sparse.hpp>

void f(boost::numeric::ublas::matrix<double> &m,
       boost::numeric::ublas::permutation_matrix<unsigned long> &pm,
       boost::numeric::ublas::mapped_vector<double> &v) {
    boost::numeric::ublas::lu_substitute(m, pm, v);
}

with gcc 4.7 on linux, I get a compile error which at its core has

/usr/include/boost/numeric/ublas/lu.hpp:71:17: error: no matching function for call to ‘swap(boost::numeric::ublas::mapped_vector<double>::reference, boost::numeric::ublas::mapped_vector<double>::reference)’

Shouldn't this be an allowed use of the classes involved?

Change History (0)

Note: See TracTickets for help on using tickets.