
5 Jun
2008
5 Jun
'08
11:08 p.m.
AMDG Eric Darve wrote:
Hi,
I found what I think is a bug in boost/multi_array.hpp. Perhaps some of you can explain what is wrong. Look at the code below. When executed you get the following error: multi_array_ref.hpp:487: failed assertion `std::equal(other.shape(),other.shape()+this->num_dimensions(), this->shape())'
This is caused by the line x.resize(extents[n+1][3]);
This seems to be by design. Multiarray doesn't have normal assignment semantics. #include "boost/multi_array.hpp" #include <vector> using boost::multi_array; using boost::extents; using std::vector; int main(void) { multi_array<int, 1> x(boost::extents[2]), y; y = x; } In Christ, Steven Watanabe