Replaced int with std::size_t when building indexes.

This commit is contained in:
Ion Gaztañaga
2016-08-23 02:13:03 +02:00
parent 2d6f781a2f
commit c7407e34f6
2 changed files with 5 additions and 5 deletions

View File

@@ -236,7 +236,7 @@ struct insert_nonmovable_emplace_proxy
{ this->priv_uninitialized_copy_some_and_update(a, index_tuple_t(), p, n); } { this->priv_uninitialized_copy_some_and_update(a, index_tuple_t(), p, n); }
private: private:
template<int ...IdxPack> template<std::size_t ...IdxPack>
void priv_uninitialized_copy_some_and_update(Allocator &a, const index_tuple<IdxPack...>&, Iterator p, size_type n) void priv_uninitialized_copy_some_and_update(Allocator &a, const index_tuple<IdxPack...>&, Iterator p, size_type n)
{ {
BOOST_ASSERT(n == 1); (void)n; BOOST_ASSERT(n == 1); (void)n;
@@ -266,7 +266,7 @@ struct insert_emplace_proxy
private: private:
template<int ...IdxPack> template<std::size_t ...IdxPack>
void priv_copy_some_and_update(Allocator &a, const index_tuple<IdxPack...>&, Iterator p, size_type n) void priv_copy_some_and_update(Allocator &a, const index_tuple<IdxPack...>&, Iterator p, size_type n)
{ {
BOOST_ASSERT(n ==1); (void)n; BOOST_ASSERT(n ==1); (void)n;

View File

@@ -135,18 +135,18 @@ typename get_impl<I, tuple<Values...> >::const_type get(const tuple<Values...>&
// in a function call. // in a function call.
//////////////////////////////////////////////////// ////////////////////////////////////////////////////
template<int... Indexes> template<std::size_t ... Indexes>
struct index_tuple{}; struct index_tuple{};
template<std::size_t Num, typename Tuple = index_tuple<> > template<std::size_t Num, typename Tuple = index_tuple<> >
struct build_number_seq; struct build_number_seq;
template<std::size_t Num, int... Indexes> template<std::size_t Num, std::size_t ... Indexes>
struct build_number_seq<Num, index_tuple<Indexes...> > struct build_number_seq<Num, index_tuple<Indexes...> >
: build_number_seq<Num - 1, index_tuple<Indexes..., sizeof...(Indexes)> > : build_number_seq<Num - 1, index_tuple<Indexes..., sizeof...(Indexes)> >
{}; {};
template<int... Indexes> template<std::size_t ... Indexes>
struct build_number_seq<0, index_tuple<Indexes...> > struct build_number_seq<0, index_tuple<Indexes...> >
{ typedef index_tuple<Indexes...> type; }; { typedef index_tuple<Indexes...> type; };