forked from boostorg/unordered
Unordered: Remove BOOST_DEDUCED_TYPENAME
[SVN r74192]
This commit is contained in:
@@ -78,14 +78,12 @@ namespace boost { namespace unordered { namespace detail {
|
||||
template <typename Alloc, typename T>
|
||||
struct rebind_wrap
|
||||
{
|
||||
typedef BOOST_DEDUCED_TYPENAME
|
||||
Alloc::BOOST_NESTED_TEMPLATE rebind<T>::other
|
||||
typedef typename Alloc::BOOST_NESTED_TEMPLATE rebind<T>::other
|
||||
type;
|
||||
};
|
||||
# endif
|
||||
|
||||
template <typename T> BOOST_DEDUCED_TYPENAME
|
||||
boost::add_lvalue_reference<T>::type make();
|
||||
template <typename T> typename boost::add_lvalue_reference<T>::type make();
|
||||
struct choice9 { typedef char (&type)[9]; };
|
||||
struct choice8 : choice9 { typedef char (&type)[8]; };
|
||||
struct choice7 : choice8 { typedef char (&type)[7]; };
|
||||
@@ -104,8 +102,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
struct default_type_ ## tname { \
|
||||
\
|
||||
template <typename X> \
|
||||
static choice1::type test(choice1, \
|
||||
BOOST_DEDUCED_TYPENAME X::tname* = 0); \
|
||||
static choice1::type test(choice1, typename X::tname* = 0); \
|
||||
\
|
||||
template <typename X> \
|
||||
static choice2::type test(choice2, void* = 0); \
|
||||
@@ -114,8 +111,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
\
|
||||
enum { value = (1 == sizeof(test<Tp>(choose()))) }; \
|
||||
\
|
||||
typedef BOOST_DEDUCED_TYPENAME \
|
||||
boost::detail::if_true<value>:: \
|
||||
typedef typename boost::detail::if_true<value>:: \
|
||||
BOOST_NESTED_TEMPLATE then<Tp, DefaultWrap> \
|
||||
::type::tname type; \
|
||||
}
|
||||
@@ -130,8 +126,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
struct default_type_ ## tname { \
|
||||
\
|
||||
template <typename X> \
|
||||
static BOOST_DEDUCED_TYPENAME sfinae< \
|
||||
BOOST_DEDUCED_TYPENAME X::tname, choice1>::type \
|
||||
static typename sfinae<typename X::tname, choice1>::type \
|
||||
test(choice1); \
|
||||
\
|
||||
template <typename X> \
|
||||
@@ -141,8 +136,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
\
|
||||
enum { value = (1 == sizeof(test<Tp>(choose()))) }; \
|
||||
\
|
||||
typedef BOOST_DEDUCED_TYPENAME \
|
||||
boost::detail::if_true<value>:: \
|
||||
typedef typename boost::detail::if_true<value>:: \
|
||||
BOOST_NESTED_TEMPLATE then<Tp, DefaultWrap> \
|
||||
::type::tname type; \
|
||||
}
|
||||
@@ -150,7 +144,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
#endif
|
||||
|
||||
#define BOOST_UNORDERED_DEFAULT_TYPE(T,tname, arg) \
|
||||
BOOST_DEDUCED_TYPENAME default_type_ ## tname<T, arg>::type
|
||||
typename default_type_ ## tname<T, arg>::type
|
||||
|
||||
BOOST_UNORDERED_DEFAULT_TYPE_TMPLT(pointer);
|
||||
BOOST_UNORDERED_DEFAULT_TYPE_TMPLT(const_pointer);
|
||||
@@ -228,7 +222,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
typedef BOOST_PP_CAT(choice, result) type; \
|
||||
}; \
|
||||
\
|
||||
template <class U> static BOOST_DEDUCED_TYPENAME \
|
||||
template <class U> static typename \
|
||||
BOOST_PP_CAT(test, count)<&U::name>::type \
|
||||
test(BOOST_PP_CAT(choice, count))
|
||||
|
||||
@@ -261,7 +255,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
#endif
|
||||
|
||||
template <typename Alloc>
|
||||
inline BOOST_DEDUCED_TYPENAME boost::enable_if<
|
||||
inline typename boost::enable_if<
|
||||
has_select_on_container_copy_construction<Alloc>, Alloc
|
||||
>::type call_select_on_container_copy_construction(const Alloc& rhs)
|
||||
{
|
||||
@@ -269,7 +263,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
}
|
||||
|
||||
template <typename Alloc>
|
||||
inline BOOST_DEDUCED_TYPENAME boost::disable_if<
|
||||
inline typename boost::disable_if<
|
||||
has_select_on_container_copy_construction<Alloc>, Alloc
|
||||
>::type call_select_on_container_copy_construction(const Alloc& rhs)
|
||||
{
|
||||
@@ -302,7 +296,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
// For now always use the allocator's const_pointer.
|
||||
|
||||
//typedef BOOST_UNORDERED_DEFAULT_TYPE(Alloc, const_pointer,
|
||||
// BOOST_DEDUCED_TYPENAME pointer_traits<pointer>::
|
||||
// typename pointer_traits<pointer>::
|
||||
// BOOST_NESTED_TEMPLATE rebind<const value_type>::other)
|
||||
// const_pointer;
|
||||
|
||||
@@ -317,7 +311,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
// void_pointer;
|
||||
|
||||
//typedef BOOST_UNORDERED_DEFAULT_TYPE(Alloc, const_void_pointer,
|
||||
// BOOST_DEDUCED_TYPENAME pointer_traits<pointer>::
|
||||
// typename pointer_traits<pointer>::
|
||||
// BOOST_NESTED_TEMPLATE rebind<const void>::other)
|
||||
// const_void_pointer;
|
||||
|
||||
@@ -409,7 +403,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
template <typename Allocator>
|
||||
struct allocator_array_constructor
|
||||
{
|
||||
typedef BOOST_DEDUCED_TYPENAME allocator_traits<Allocator>::pointer
|
||||
typedef typename allocator_traits<Allocator>::pointer
|
||||
pointer;
|
||||
|
||||
Allocator& alloc_;
|
||||
|
||||
@@ -41,7 +41,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
public:
|
||||
// Types
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME ::boost::detail::if_true<Unique>::
|
||||
typedef typename ::boost::detail::if_true<Unique>::
|
||||
BOOST_NESTED_TEMPLATE then<
|
||||
::boost::unordered::detail::ungrouped_node<A>,
|
||||
::boost::unordered::detail::grouped_node<A>
|
||||
@@ -49,16 +49,15 @@ namespace boost { namespace unordered { namespace detail {
|
||||
|
||||
typedef A value_allocator;
|
||||
typedef ::boost::unordered::detail::bucket<A> bucket;
|
||||
typedef BOOST_DEDUCED_TYPENAME allocator_traits<A>::value_type value_type;
|
||||
typedef typename allocator_traits<A>::value_type value_type;
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME bucket::bucket_allocator
|
||||
bucket_allocator;
|
||||
typedef BOOST_DEDUCED_TYPENAME allocator_traits<bucket_allocator>::pointer bucket_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME bucket::node_ptr node_ptr;
|
||||
typedef typename bucket::bucket_allocator bucket_allocator;
|
||||
typedef typename allocator_traits<bucket_allocator>::pointer bucket_ptr;
|
||||
typedef typename bucket::node_ptr node_ptr;
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME rebind_wrap<value_allocator, node>::type
|
||||
typedef typename rebind_wrap<value_allocator, node>::type
|
||||
node_allocator;
|
||||
typedef BOOST_DEDUCED_TYPENAME allocator_traits<node_allocator>::pointer real_node_ptr;
|
||||
typedef typename allocator_traits<node_allocator>::pointer real_node_ptr;
|
||||
|
||||
// Members
|
||||
|
||||
@@ -423,7 +422,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
functions& operator=(functions const&);
|
||||
|
||||
typedef compressed_pair<H, P> function_pair;
|
||||
typedef BOOST_DEDUCED_TYPENAME ::boost::aligned_storage<
|
||||
typedef typename ::boost::aligned_storage<
|
||||
sizeof(function_pair),
|
||||
::boost::alignment_of<function_pair>::value>::type aligned_function;
|
||||
|
||||
@@ -647,7 +646,7 @@ BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(10, std::tr1)
|
||||
}
|
||||
|
||||
template <class T, class Arg1>
|
||||
inline BOOST_DEDUCED_TYPENAME normal_construct1<T, Arg1>::type
|
||||
inline typename normal_construct1<T, Arg1>::type
|
||||
construct_impl(void* address, BOOST_FWD_REF(Arg1) arg1)
|
||||
{
|
||||
new(address) T(
|
||||
@@ -656,14 +655,14 @@ BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(10, std::tr1)
|
||||
}
|
||||
|
||||
template <class T, class Arg1>
|
||||
inline BOOST_DEDUCED_TYPENAME pair_construct1<T, Arg1>::type
|
||||
inline typename pair_construct1<T, Arg1>::type
|
||||
construct_impl(void* address, BOOST_FWD_REF(Arg1) arg1)
|
||||
{
|
||||
new((void*)(&static_cast<T*>(address)->first))
|
||||
BOOST_DEDUCED_TYPENAME T::first_type(
|
||||
typename T::first_type(
|
||||
boost::forward<Arg1>(arg1));
|
||||
new((void*)(&static_cast<T*>(address)->second))
|
||||
BOOST_DEDUCED_TYPENAME T::second_type();
|
||||
typename T::second_type();
|
||||
}
|
||||
|
||||
template <class T, class Arg1, class Arg2>
|
||||
@@ -676,7 +675,7 @@ BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(10, std::tr1)
|
||||
}
|
||||
|
||||
template <class T, class Arg1, class Arg2, class Arg3>
|
||||
inline BOOST_DEDUCED_TYPENAME piecewise_construct3<T, Arg1>::type
|
||||
inline typename piecewise_construct3<T, Arg1>::type
|
||||
construct_impl(void* address, BOOST_FWD_REF(Arg1),
|
||||
BOOST_FWD_REF(Arg2) arg2, BOOST_FWD_REF(Arg3) arg3)
|
||||
{
|
||||
@@ -685,21 +684,21 @@ BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(10, std::tr1)
|
||||
}
|
||||
|
||||
template <class T, class Arg1, class Arg2, class Arg3>
|
||||
inline BOOST_DEDUCED_TYPENAME pair_construct3<T, Arg1>::type
|
||||
inline typename pair_construct3<T, Arg1>::type
|
||||
construct_impl(void* address, BOOST_FWD_REF(Arg1) arg1,
|
||||
BOOST_FWD_REF(Arg2) arg2, BOOST_FWD_REF(Arg3) arg3)
|
||||
{
|
||||
new((void*)(&static_cast<T*>(address)->first))
|
||||
BOOST_DEDUCED_TYPENAME T::first_type(
|
||||
typename T::first_type(
|
||||
boost::forward<Arg1>(arg1));
|
||||
new((void*)(&static_cast<T*>(address)->second))
|
||||
BOOST_DEDUCED_TYPENAME T::second_type(
|
||||
typename T::second_type(
|
||||
boost::forward<Arg2>(arg2),
|
||||
boost::forward<Arg3>(arg3));
|
||||
}
|
||||
|
||||
template <class T, class Arg1, class Arg2, class Arg3>
|
||||
inline BOOST_DEDUCED_TYPENAME normal_construct3<T, Arg1>::type
|
||||
inline typename normal_construct3<T, Arg1>::type
|
||||
construct_impl(void* address, BOOST_FWD_REF(Arg1) arg1,
|
||||
BOOST_FWD_REF(Arg2) arg2, BOOST_FWD_REF(Arg3) arg3)
|
||||
{
|
||||
@@ -712,7 +711,7 @@ BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(10, std::tr1)
|
||||
#if defined(BOOST_UNORDERED_STD_FORWARD_MOVE)
|
||||
|
||||
template <class T, class Arg1, class Arg2, class Arg3, class Arg4, class... Args>
|
||||
inline BOOST_DEDUCED_TYPENAME normal_construct_n<T>::type
|
||||
inline typename normal_construct_n<T>::type
|
||||
construct_impl(void* address, Arg1&& arg1, Arg2&& arg2, Arg3&& arg3,
|
||||
Arg4&& arg4, Args&&... args)
|
||||
{
|
||||
@@ -725,15 +724,15 @@ BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(10, std::tr1)
|
||||
}
|
||||
|
||||
template <class T, class Arg1, class Arg2, class Arg3, class Arg4, class... Args>
|
||||
inline BOOST_DEDUCED_TYPENAME pair_construct_n<T>::type
|
||||
inline typename pair_construct_n<T>::type
|
||||
construct_impl(void* address, Arg1&& arg1, Arg2&& arg2, Arg3&& arg3,
|
||||
Arg4&& arg4, Args&&... args)
|
||||
{
|
||||
new((void*)(&static_cast<T*>(address)->first))
|
||||
BOOST_DEDUCED_TYPENAME T::first_type(
|
||||
typename T::first_type(
|
||||
std::forward<Arg1>(arg1));
|
||||
new((void*)(&static_cast<T*>(address)->second))
|
||||
BOOST_DEDUCED_TYPENAME T::second_type(
|
||||
typename T::second_type(
|
||||
std::forward<Arg2>(arg2),
|
||||
std::forward<Arg3>(arg3),
|
||||
std::forward<Arg4>(arg4),
|
||||
@@ -747,7 +746,7 @@ BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(10, std::tr1)
|
||||
class T, \
|
||||
BOOST_UNORDERED_TEMPLATE_ARGS(z, num_params) \
|
||||
> \
|
||||
inline BOOST_DEDUCED_TYPENAME normal_construct_n<T>::type \
|
||||
inline typename normal_construct_n<T>::type \
|
||||
construct_impl(void* address, \
|
||||
BOOST_UNORDERED_FUNCTION_PARAMS(z, num_params)) \
|
||||
{ \
|
||||
@@ -762,15 +761,15 @@ BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(10, std::tr1)
|
||||
template <class T, class Key, \
|
||||
BOOST_UNORDERED_TEMPLATE_ARGS(z, num_params) \
|
||||
> \
|
||||
inline BOOST_DEDUCED_TYPENAME pair_construct_n<T>::type \
|
||||
inline typename pair_construct_n<T>::type \
|
||||
construct_impl(void* address, BOOST_FWD_REF(Key) key, \
|
||||
BOOST_UNORDERED_FUNCTION_PARAMS(z, num_params)) \
|
||||
{ \
|
||||
new((void*)(&static_cast<T*>(address)->first)) \
|
||||
BOOST_DEDUCED_TYPENAME T::first_type( \
|
||||
typename T::first_type( \
|
||||
boost::forward<Key>(key)); \
|
||||
new((void*)(&static_cast<T*>(address)->second)) \
|
||||
BOOST_DEDUCED_TYPENAME T::second_type( \
|
||||
typename T::second_type( \
|
||||
BOOST_UNORDERED_CALL_PARAMS(z, num_params)); \
|
||||
}
|
||||
|
||||
@@ -788,10 +787,10 @@ BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(10, std::tr1)
|
||||
class node_constructor
|
||||
{
|
||||
typedef ::boost::unordered::detail::buckets<Alloc, Unique> buckets;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::node node;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::real_node_ptr real_node_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::value_type value_type;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::node_allocator node_allocator;
|
||||
typedef typename buckets::node node;
|
||||
typedef typename buckets::real_node_ptr real_node_ptr;
|
||||
typedef typename buckets::value_type value_type;
|
||||
typedef typename buckets::node_allocator node_allocator;
|
||||
|
||||
buckets& buckets_;
|
||||
real_node_ptr node_;
|
||||
@@ -858,7 +857,7 @@ BOOST_UNORDERED_CONSTRUCT_FROM_TUPLE(10, std::tr1)
|
||||
}
|
||||
|
||||
// no throw
|
||||
BOOST_DEDUCED_TYPENAME buckets::node_ptr release()
|
||||
typename buckets::node_ptr release()
|
||||
{
|
||||
real_node_ptr p = node_;
|
||||
node_ = real_node_ptr();
|
||||
|
||||
@@ -15,19 +15,19 @@ namespace boost { namespace unordered { namespace detail {
|
||||
class equivalent_table : public T::table_base
|
||||
{
|
||||
public:
|
||||
typedef BOOST_DEDUCED_TYPENAME T::hasher hasher;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::key_equal key_equal;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::value_allocator value_allocator;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::key_type key_type;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::value_type value_type;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::table_base table_base;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::node_constructor node_constructor;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::node_allocator node_allocator;
|
||||
typedef typename T::hasher hasher;
|
||||
typedef typename T::key_equal key_equal;
|
||||
typedef typename T::value_allocator value_allocator;
|
||||
typedef typename T::key_type key_type;
|
||||
typedef typename T::value_type value_type;
|
||||
typedef typename T::table_base table_base;
|
||||
typedef typename T::node_constructor node_constructor;
|
||||
typedef typename T::node_allocator node_allocator;
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME T::node node;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::node_ptr node_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::bucket_ptr bucket_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::extractor extractor;
|
||||
typedef typename T::node node;
|
||||
typedef typename T::node_ptr node_ptr;
|
||||
typedef typename T::bucket_ptr bucket_ptr;
|
||||
typedef typename T::extractor extractor;
|
||||
|
||||
// Constructors
|
||||
|
||||
@@ -298,19 +298,18 @@ namespace boost { namespace unordered { namespace detail {
|
||||
template <class I>
|
||||
void insert_range(I i, I j)
|
||||
{
|
||||
BOOST_DEDUCED_TYPENAME ::boost::iterator_traversal<I>::type
|
||||
iterator_traversal_tag;
|
||||
insert_for_range(i, j, iterator_traversal_tag);
|
||||
insert_for_range(i, j,
|
||||
BOOST_DEDUCED_TYPENAME ::boost::iterator_traversal<I>::type());
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
template <class H, class P, class A>
|
||||
struct multiset : public types<
|
||||
BOOST_DEDUCED_TYPENAME allocator_traits<A>::value_type,
|
||||
BOOST_DEDUCED_TYPENAME allocator_traits<A>::value_type,
|
||||
typename allocator_traits<A>::value_type,
|
||||
typename allocator_traits<A>::value_type,
|
||||
H, P, A,
|
||||
set_extractor<BOOST_DEDUCED_TYPENAME allocator_traits<A>::value_type>,
|
||||
set_extractor<typename allocator_traits<A>::value_type>,
|
||||
false>
|
||||
{
|
||||
typedef equivalent_table<multiset<H, P, A> > impl;
|
||||
@@ -319,9 +318,9 @@ namespace boost { namespace unordered { namespace detail {
|
||||
|
||||
template <class K, class H, class P, class A>
|
||||
struct multimap : public types<
|
||||
K, BOOST_DEDUCED_TYPENAME allocator_traits<A>::value_type,
|
||||
K, typename allocator_traits<A>::value_type,
|
||||
H, P, A,
|
||||
map_extractor<K, BOOST_DEDUCED_TYPENAME allocator_traits<A>::value_type>,
|
||||
map_extractor<K, typename allocator_traits<A>::value_type>,
|
||||
false>
|
||||
{
|
||||
typedef equivalent_table<multimap<K, H, P, A> > impl;
|
||||
|
||||
@@ -35,8 +35,7 @@ namespace detail {
|
||||
|
||||
enum { value = sizeof(test(make<T>())) == sizeof(choice2::type) };
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME
|
||||
boost::detail::if_true<value>::
|
||||
typedef typename boost::detail::if_true<value>::
|
||||
BOOST_NESTED_TEMPLATE then<Key const&, no_key>::type type;
|
||||
};
|
||||
|
||||
@@ -94,7 +93,7 @@ namespace detail {
|
||||
struct map_extractor
|
||||
{
|
||||
typedef ValueType value_type;
|
||||
typedef BOOST_DEDUCED_TYPENAME ::boost::remove_const<Key>::type key_type;
|
||||
typedef typename ::boost::remove_const<Key>::type key_type;
|
||||
|
||||
static key_type const& extract(value_type const& v)
|
||||
{
|
||||
@@ -176,11 +175,11 @@ namespace detail {
|
||||
} \
|
||||
\
|
||||
template <typename T, typename T2> \
|
||||
static BOOST_DEDUCED_TYPENAME is_key<key_type, T>::type \
|
||||
static typename is_key<key_type, T>::type \
|
||||
extract(boost::unordered::piecewise_construct_t, \
|
||||
namespace_::tuple<T> const& k, T2&&) \
|
||||
{ \
|
||||
return BOOST_DEDUCED_TYPENAME is_key<key_type, T>::type( \
|
||||
return typename is_key<key_type, T>::type( \
|
||||
namespace_::get<0>(k)); \
|
||||
}
|
||||
|
||||
@@ -194,11 +193,11 @@ namespace detail {
|
||||
} \
|
||||
\
|
||||
template <typename T> \
|
||||
static BOOST_DEDUCED_TYPENAME is_key<key_type, T>::type \
|
||||
static typename is_key<key_type, T>::type \
|
||||
extract(boost::unordered::piecewise_construct_t, \
|
||||
namespace_::tuple<T> const& k) \
|
||||
{ \
|
||||
return BOOST_DEDUCED_TYPENAME is_key<key_type, T>::type( \
|
||||
return typename is_key<key_type, T>::type( \
|
||||
namespace_::get<0>(k)); \
|
||||
}
|
||||
|
||||
|
||||
@@ -59,11 +59,9 @@ namespace boost { namespace unordered { namespace detail {
|
||||
{
|
||||
bucket& operator=(bucket const&);
|
||||
public:
|
||||
typedef BOOST_DEDUCED_TYPENAME
|
||||
::boost::unordered::detail::rebind_wrap<A, bucket>::type
|
||||
typedef typename ::boost::unordered::detail::rebind_wrap<A, bucket>::type
|
||||
bucket_allocator;
|
||||
typedef BOOST_DEDUCED_TYPENAME
|
||||
allocator_traits<bucket_allocator>::pointer bucket_ptr;
|
||||
typedef typename allocator_traits<bucket_allocator>::pointer bucket_ptr;
|
||||
typedef bucket_ptr node_ptr;
|
||||
|
||||
node_ptr next_;
|
||||
@@ -77,7 +75,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
struct value_base
|
||||
{
|
||||
typedef ValueType value_type;
|
||||
BOOST_DEDUCED_TYPENAME ::boost::aligned_storage<
|
||||
typename ::boost::aligned_storage<
|
||||
sizeof(value_type),
|
||||
::boost::alignment_of<value_type>::value>::type data_;
|
||||
|
||||
@@ -107,12 +105,12 @@ namespace boost { namespace unordered { namespace detail {
|
||||
template <class A>
|
||||
struct ungrouped_node
|
||||
: ::boost::unordered::detail::bucket<A>,
|
||||
value_base<BOOST_DEDUCED_TYPENAME allocator_traits<A>::value_type>
|
||||
value_base<typename allocator_traits<A>::value_type>
|
||||
{
|
||||
typedef ::boost::unordered::detail::bucket<A> bucket;
|
||||
typedef BOOST_DEDUCED_TYPENAME bucket::bucket_ptr bucket_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME bucket::node_ptr node_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME allocator_traits<A>::value_type value_type;
|
||||
typedef typename bucket::bucket_ptr bucket_ptr;
|
||||
typedef typename bucket::node_ptr node_ptr;
|
||||
typedef typename allocator_traits<A>::value_type value_type;
|
||||
|
||||
std::size_t hash_;
|
||||
|
||||
@@ -182,12 +180,12 @@ namespace boost { namespace unordered { namespace detail {
|
||||
template <class A>
|
||||
struct grouped_node
|
||||
: ::boost::unordered::detail::bucket<A>,
|
||||
value_base<BOOST_DEDUCED_TYPENAME allocator_traits<A>::value_type>
|
||||
value_base<typename allocator_traits<A>::value_type>
|
||||
{
|
||||
typedef ::boost::unordered::detail::bucket<A> bucket;
|
||||
typedef BOOST_DEDUCED_TYPENAME bucket::bucket_ptr bucket_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME bucket::node_ptr node_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME allocator_traits<A>::value_type value_type;
|
||||
typedef typename bucket::bucket_ptr bucket_ptr;
|
||||
typedef typename bucket::node_ptr node_ptr;
|
||||
typedef typename allocator_traits<A>::value_type value_type;
|
||||
|
||||
std::size_t hash_;
|
||||
node_ptr group_prev_;
|
||||
|
||||
@@ -23,22 +23,22 @@ namespace boost { namespace unordered { namespace detail {
|
||||
table(table const&);
|
||||
table& operator=(table const&);
|
||||
public:
|
||||
typedef BOOST_DEDUCED_TYPENAME T::hasher hasher;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::key_equal key_equal;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::value_allocator value_allocator;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::key_type key_type;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::value_type value_type;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::functions functions;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::buckets buckets;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::extractor extractor;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::node_constructor node_constructor;
|
||||
typedef typename T::hasher hasher;
|
||||
typedef typename T::key_equal key_equal;
|
||||
typedef typename T::value_allocator value_allocator;
|
||||
typedef typename T::key_type key_type;
|
||||
typedef typename T::value_type value_type;
|
||||
typedef typename T::functions functions;
|
||||
typedef typename T::buckets buckets;
|
||||
typedef typename T::extractor extractor;
|
||||
typedef typename T::node_constructor node_constructor;
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME T::node node;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::bucket bucket;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::node_ptr node_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::bucket_ptr bucket_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::node_allocator node_allocator;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::iterator_pair iterator_pair;
|
||||
typedef typename T::node node;
|
||||
typedef typename T::bucket bucket;
|
||||
typedef typename T::node_ptr node_ptr;
|
||||
typedef typename T::bucket_ptr bucket_ptr;
|
||||
typedef typename T::node_allocator node_allocator;
|
||||
typedef typename T::iterator_pair iterator_pair;
|
||||
|
||||
// Members
|
||||
|
||||
@@ -485,11 +485,11 @@ namespace boost { namespace unordered { namespace detail {
|
||||
typedef ::boost::unordered::detail::buckets<value_allocator, Unique> buckets;
|
||||
typedef ::boost::unordered::detail::functions<hasher, key_equal> functions;
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::node node;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::bucket bucket;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::node_ptr node_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::bucket_ptr bucket_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::node_allocator node_allocator;
|
||||
typedef typename buckets::node node;
|
||||
typedef typename buckets::bucket bucket;
|
||||
typedef typename buckets::node_ptr node_ptr;
|
||||
typedef typename buckets::bucket_ptr bucket_ptr;
|
||||
typedef typename buckets::node_allocator node_allocator;
|
||||
|
||||
typedef std::pair<node_ptr, node_ptr> iterator_pair;
|
||||
};
|
||||
@@ -514,18 +514,18 @@ namespace boost { namespace unordered { namespace iterator_detail {
|
||||
class l_iterator
|
||||
: public ::boost::iterator <
|
||||
std::forward_iterator_tag,
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type,
|
||||
typename boost::unordered::detail::allocator_traits<A>::value_type,
|
||||
std::ptrdiff_t,
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::pointer,
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type&>
|
||||
typename boost::unordered::detail::allocator_traits<A>::pointer,
|
||||
typename boost::unordered::detail::allocator_traits<A>::value_type&>
|
||||
{
|
||||
public:
|
||||
typedef BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type value_type;
|
||||
typedef typename boost::unordered::detail::allocator_traits<A>::value_type value_type;
|
||||
|
||||
private:
|
||||
typedef ::boost::unordered::detail::buckets<A, Unique> buckets;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::node_ptr node_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::node node;
|
||||
typedef typename buckets::node_ptr node_ptr;
|
||||
typedef typename buckets::node node;
|
||||
typedef cl_iterator<A, Unique> const_local_iterator;
|
||||
|
||||
friend class cl_iterator<A, Unique>;
|
||||
@@ -538,7 +538,7 @@ namespace boost { namespace unordered { namespace iterator_detail {
|
||||
l_iterator() : ptr_() {}
|
||||
l_iterator(node_ptr x, std::size_t b, std::size_t c)
|
||||
: ptr_(x), bucket_(b), bucket_count_(c) {}
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type& operator*() const {
|
||||
typename boost::unordered::detail::allocator_traits<A>::value_type& operator*() const {
|
||||
return node::get_value(ptr_);
|
||||
}
|
||||
value_type* operator->() const {
|
||||
@@ -575,18 +575,18 @@ namespace boost { namespace unordered { namespace iterator_detail {
|
||||
class cl_iterator
|
||||
: public ::boost::iterator <
|
||||
std::forward_iterator_tag,
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type,
|
||||
typename boost::unordered::detail::allocator_traits<A>::value_type,
|
||||
std::ptrdiff_t,
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::const_pointer,
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type const& >
|
||||
typename boost::unordered::detail::allocator_traits<A>::const_pointer,
|
||||
typename boost::unordered::detail::allocator_traits<A>::value_type const& >
|
||||
{
|
||||
public:
|
||||
typedef BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type value_type;
|
||||
typedef typename boost::unordered::detail::allocator_traits<A>::value_type value_type;
|
||||
|
||||
private:
|
||||
typedef ::boost::unordered::detail::buckets<A, Unique> buckets;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::node_ptr node_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::node node;
|
||||
typedef typename buckets::node_ptr node_ptr;
|
||||
typedef typename buckets::node node;
|
||||
typedef l_iterator<A, Unique> local_iterator;
|
||||
|
||||
friend class l_iterator<A, Unique>;
|
||||
@@ -602,7 +602,7 @@ namespace boost { namespace unordered { namespace iterator_detail {
|
||||
cl_iterator(local_iterator x)
|
||||
: ptr_(x.ptr_), bucket_(x.bucket_), bucket_count_(x.bucket_count_)
|
||||
{}
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type const&
|
||||
typename boost::unordered::detail::allocator_traits<A>::value_type const&
|
||||
operator*() const {
|
||||
return node::get_value(ptr_);
|
||||
}
|
||||
@@ -640,18 +640,18 @@ namespace boost { namespace unordered { namespace iterator_detail {
|
||||
class iterator
|
||||
: public ::boost::iterator <
|
||||
std::forward_iterator_tag,
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type,
|
||||
typename boost::unordered::detail::allocator_traits<A>::value_type,
|
||||
std::ptrdiff_t,
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::pointer,
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type& >
|
||||
typename boost::unordered::detail::allocator_traits<A>::pointer,
|
||||
typename boost::unordered::detail::allocator_traits<A>::value_type& >
|
||||
{
|
||||
public:
|
||||
typedef BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type value_type;
|
||||
typedef typename boost::unordered::detail::allocator_traits<A>::value_type value_type;
|
||||
|
||||
private:
|
||||
typedef ::boost::unordered::detail::buckets<A, Unique> buckets;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::node node;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::node_ptr node_ptr;
|
||||
typedef typename buckets::node node;
|
||||
typedef typename buckets::node_ptr node_ptr;
|
||||
typedef c_iterator<A, Unique> const_iterator;
|
||||
friend class c_iterator<A, Unique>;
|
||||
node_ptr node_;
|
||||
@@ -660,7 +660,7 @@ namespace boost { namespace unordered { namespace iterator_detail {
|
||||
|
||||
iterator() : node_() {}
|
||||
explicit iterator(node_ptr const& x) : node_(x) {}
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type& operator*() const {
|
||||
typename boost::unordered::detail::allocator_traits<A>::value_type& operator*() const {
|
||||
return node::get_value(node_);
|
||||
}
|
||||
value_type* operator->() const {
|
||||
@@ -690,18 +690,18 @@ namespace boost { namespace unordered { namespace iterator_detail {
|
||||
class c_iterator
|
||||
: public ::boost::iterator <
|
||||
std::forward_iterator_tag,
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type,
|
||||
typename boost::unordered::detail::allocator_traits<A>::value_type,
|
||||
std::ptrdiff_t,
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::const_pointer,
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type const& >
|
||||
typename boost::unordered::detail::allocator_traits<A>::const_pointer,
|
||||
typename boost::unordered::detail::allocator_traits<A>::value_type const& >
|
||||
{
|
||||
public:
|
||||
typedef BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type value_type;
|
||||
typedef typename boost::unordered::detail::allocator_traits<A>::value_type value_type;
|
||||
|
||||
private:
|
||||
typedef ::boost::unordered::detail::buckets<A, Unique> buckets;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::node node;
|
||||
typedef BOOST_DEDUCED_TYPENAME buckets::node_ptr node_ptr;
|
||||
typedef typename buckets::node node;
|
||||
typedef typename buckets::node_ptr node_ptr;
|
||||
typedef ::boost::unordered::iterator_detail::iterator<A, Unique>
|
||||
iterator;
|
||||
friend class ::boost::unordered::iterator_detail::iterator<A, Unique>;
|
||||
@@ -726,7 +726,7 @@ namespace boost { namespace unordered { namespace iterator_detail {
|
||||
c_iterator() : node_() {}
|
||||
explicit c_iterator(node_ptr const& x) : node_(x) {}
|
||||
c_iterator(iterator const& x) : node_(x.node_) {}
|
||||
BOOST_DEDUCED_TYPENAME boost::unordered::detail::allocator_traits<A>::value_type const& operator*() const {
|
||||
typename boost::unordered::detail::allocator_traits<A>::value_type const& operator*() const {
|
||||
return node::get_value(node_);
|
||||
}
|
||||
value_type const* operator->() const {
|
||||
|
||||
@@ -15,19 +15,19 @@ namespace boost { namespace unordered { namespace detail {
|
||||
class unique_table : public T::table_base
|
||||
{
|
||||
public:
|
||||
typedef BOOST_DEDUCED_TYPENAME T::hasher hasher;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::key_equal key_equal;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::value_allocator value_allocator;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::key_type key_type;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::value_type value_type;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::table_base table_base;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::node_constructor node_constructor;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::node_allocator node_allocator;
|
||||
typedef typename T::hasher hasher;
|
||||
typedef typename T::key_equal key_equal;
|
||||
typedef typename T::value_allocator value_allocator;
|
||||
typedef typename T::key_type key_type;
|
||||
typedef typename T::value_type value_type;
|
||||
typedef typename T::table_base table_base;
|
||||
typedef typename T::node_constructor node_constructor;
|
||||
typedef typename T::node_allocator node_allocator;
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME T::node node;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::node_ptr node_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::bucket_ptr bucket_ptr;
|
||||
typedef BOOST_DEDUCED_TYPENAME T::extractor extractor;
|
||||
typedef typename T::node node;
|
||||
typedef typename T::node_ptr node_ptr;
|
||||
typedef typename T::bucket_ptr bucket_ptr;
|
||||
typedef typename T::extractor extractor;
|
||||
|
||||
typedef std::pair<node_ptr, bool> emplace_return;
|
||||
|
||||
@@ -118,7 +118,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
|
||||
value_type& operator[](key_type const& k)
|
||||
{
|
||||
typedef BOOST_DEDUCED_TYPENAME value_type::second_type mapped_type;
|
||||
typedef typename value_type::second_type mapped_type;
|
||||
|
||||
std::size_t hash = this->hash_function()(k);
|
||||
std::size_t bucket_index = hash % this->bucket_count_;
|
||||
@@ -399,10 +399,10 @@ namespace boost { namespace unordered { namespace detail {
|
||||
|
||||
template <class H, class P, class A>
|
||||
struct set : public types<
|
||||
BOOST_DEDUCED_TYPENAME allocator_traits<A>::value_type,
|
||||
BOOST_DEDUCED_TYPENAME allocator_traits<A>::value_type,
|
||||
typename allocator_traits<A>::value_type,
|
||||
typename allocator_traits<A>::value_type,
|
||||
H, P, A,
|
||||
set_extractor<BOOST_DEDUCED_TYPENAME allocator_traits<A>::value_type>,
|
||||
set_extractor<typename allocator_traits<A>::value_type>,
|
||||
true>
|
||||
{
|
||||
typedef ::boost::unordered::detail::unique_table<set<H, P, A> > impl;
|
||||
@@ -411,9 +411,9 @@ namespace boost { namespace unordered { namespace detail {
|
||||
|
||||
template <class K, class H, class P, class A>
|
||||
struct map : public types<
|
||||
K, BOOST_DEDUCED_TYPENAME allocator_traits<A>::value_type,
|
||||
K, typename allocator_traits<A>::value_type,
|
||||
H, P, A,
|
||||
map_extractor<K, BOOST_DEDUCED_TYPENAME allocator_traits<A>::value_type>,
|
||||
map_extractor<K, typename allocator_traits<A>::value_type>,
|
||||
true>
|
||||
{
|
||||
typedef ::boost::unordered::detail::unique_table<map<K, H, P, A> > impl;
|
||||
|
||||
@@ -234,7 +234,7 @@ namespace boost { namespace unordered { namespace detail {
|
||||
inline std::size_t insert_size(I i, I j)
|
||||
{
|
||||
return insert_size(i, j,
|
||||
BOOST_DEDUCED_TYPENAME ::boost::iterator_traversal<I>::type());
|
||||
typename ::boost::iterator_traversal<I>::type());
|
||||
}
|
||||
|
||||
template <class I>
|
||||
@@ -285,8 +285,8 @@ namespace boost { namespace unordered { namespace detail {
|
||||
: private generate_base<T1, 1>::type,
|
||||
private generate_base<T2, 2>::type
|
||||
{
|
||||
typedef BOOST_DEDUCED_TYPENAME generate_base<T1, 1>::type base1;
|
||||
typedef BOOST_DEDUCED_TYPENAME generate_base<T2, 2>::type base2;
|
||||
typedef typename generate_base<T1, 1>::type base1;
|
||||
typedef typename generate_base<T2, 2>::type base2;
|
||||
|
||||
typedef T1 first_type;
|
||||
typedef T2 second_type;
|
||||
|
||||
Reference in New Issue
Block a user