Files
multi_array/test/vc_death.cpp
Ronald Garcia 685b7e4c37 Initial submission to Boost.
[SVN r13915]
2002-05-15 16:08:54 +00:00

34 lines
700 B
C++

//
// index_bases - test of the index_base modifying facilities.
//
#include "boost/multi_array.hpp"
#define BOOST_INCLUDE_MAIN
#include "boost/test/test_tools.hpp"
#include "boost/array.hpp"
#include <vector>
#include <iostream>
int
test_main(int,char**)
{
typedef boost::multi_array<double, 3> array;
typedef array::array_view<3>::type array_view;
typedef array::extent_range erange;
typedef array::index_range irange;
array::extent_gen extents;
array::index_gen indices;
// Construct with nonzero bases
{
array A(extents[erange(1,4)][erange(2,5)][erange(3,6)]);
array_view E = A[indices[irange(1,2)][irange(1,2)][irange(1,2)]];
}
return boost::exit_success;
}