
On 18 December 2012 08:24, gast128
I am talking about multi_array, see title. Example code:
void f() { typedef boost::multi_array
Matrix; Matrix m1(boost::extents[2][3]); _ASSERT(m1.size() == 2); _ASSERT(m1[0].size() == 3);
m1.resize(boost::extents[0][3]); _ASSERT(m1.size() == 0); //_ASSERT(m1[0].size() == 3); //<--assert }
Hi,
The shape function has the list of multi_array dimensions.
This should do it:
#include