2013-08-08 09:54:33 +00:00
|
|
|
/*=============================================================================
|
|
|
|
Copyright (c) 2011-2013 Bolero MURAKAMI
|
|
|
|
https://github.com/bolero-MURAKAMI/Sprout
|
|
|
|
|
|
|
|
Distributed under the Boost Software License, Version 1.0. (See accompanying
|
|
|
|
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
|
|
|
=============================================================================*/
|
2013-03-31 04:39:26 +00:00
|
|
|
#ifndef SPROUT_INDEX_TUPLE_MAKE_INDEX_TUPLE_HPP
|
|
|
|
#define SPROUT_INDEX_TUPLE_MAKE_INDEX_TUPLE_HPP
|
|
|
|
|
|
|
|
#include <sprout/config.hpp>
|
|
|
|
#include <sprout/index_tuple/index_tuple.hpp>
|
2013-05-10 10:52:39 +00:00
|
|
|
#include <sprout/index_tuple/make_integer_sequence.hpp>
|
2013-04-06 04:06:51 +00:00
|
|
|
#include <sprout/index_tuple/enable_make_indexes.hpp>
|
2013-03-31 04:39:26 +00:00
|
|
|
|
|
|
|
namespace sprout {
|
|
|
|
//
|
|
|
|
// make_index_tuple
|
2013-05-10 12:53:53 +00:00
|
|
|
// make_uindex_tuple
|
2013-03-31 04:39:26 +00:00
|
|
|
//
|
2013-05-10 12:53:53 +00:00
|
|
|
#if SPROUT_USE_TEMPLATE_ALIASES
|
|
|
|
template<sprout::index_t N>
|
|
|
|
using make_index_tuple = sprout::make_integer_sequence<sprout::index_t, N>;
|
|
|
|
|
|
|
|
template<sprout::uindex_t N>
|
|
|
|
using make_uindex_tuple = sprout::make_integer_sequence<sprout::uindex_t, N>;
|
|
|
|
#else // #if SPROUT_USE_TEMPLATE_ALIASES
|
2013-03-31 04:39:26 +00:00
|
|
|
template<sprout::index_t N>
|
|
|
|
struct make_index_tuple
|
2013-04-06 04:06:51 +00:00
|
|
|
: public sprout::enable_make_indexes<
|
2013-05-10 10:52:39 +00:00
|
|
|
typename sprout::make_integer_sequence<sprout::index_t, N>::type
|
2013-03-31 04:39:26 +00:00
|
|
|
::template transfer<sprout::index_tuple<> >::type
|
|
|
|
>
|
|
|
|
{};
|
2013-05-10 12:53:53 +00:00
|
|
|
|
2013-03-31 04:39:26 +00:00
|
|
|
template<sprout::uindex_t N>
|
|
|
|
struct make_uindex_tuple
|
2013-04-06 04:06:51 +00:00
|
|
|
: public sprout::enable_make_indexes<
|
2013-05-10 10:52:39 +00:00
|
|
|
typename sprout::make_integer_sequence<sprout::uindex_t, N>::type
|
2013-03-31 04:39:26 +00:00
|
|
|
::template transfer<sprout::uindex_tuple<> >::type
|
|
|
|
>
|
|
|
|
{};
|
2013-05-10 12:53:53 +00:00
|
|
|
#endif // #if SPROUT_USE_TEMPLATE_ALIASES
|
2013-03-31 04:39:26 +00:00
|
|
|
} // namespace sprout
|
|
|
|
|
|
|
|
#endif // #ifndef SPROUT_INDEX_TUPLE_MAKE_INDEX_TUPLE_HPP
|