const_range.hpp 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. /*
  2. [auto_generated]
  3. libs/numeric/odeint/test/const_range.hpp
  4. [begin_description]
  5. tba.
  6. [end_description]
  7. Copyright 2012 Karsten Ahnert
  8. Copyright 2012 Mario Mulansky
  9. Distributed under the Boost Software License, Version 1.0.
  10. (See accompanying file LICENSE_1_0.txt or
  11. copy at http://www.boost.org/LICENSE_1_0.txt)
  12. */
  13. #ifndef LIBS_NUMERIC_ODEINT_TEST_CONST_RANGE_HPP_DEFINED
  14. #define LIBS_NUMERIC_ODEINT_TEST_CONST_RANGE_HPP_DEFINED
  15. #include <boost/mpl/copy.hpp>
  16. #include <boost/mpl/inserter.hpp>
  17. #include <boost/mpl/insert.hpp>
  18. #include <boost/mpl/end.hpp>
  19. #include <boost/mpl/vector.hpp>
  20. #include <boost/mpl/range_c.hpp>
  21. #include <boost/mpl/placeholders.hpp>
  22. namespace mpl = boost::mpl;
  23. template< class N , class T >
  24. struct const_range
  25. {
  26. typedef typename mpl::copy<
  27. mpl::range_c< typename N::value_type , 0 , N::value > ,
  28. mpl::inserter<
  29. mpl::vector0<> ,
  30. mpl::insert<
  31. mpl::_1 ,
  32. mpl::end< mpl::_1 > ,
  33. T
  34. >
  35. >
  36. >::type type;
  37. };
  38. #endif // LIBS_NUMERIC_ODEINT_TEST_CONST_RANGE_HPP_DEFINED