forked from boostorg/unordered
Unordered: Merge from trunk
- Remove use of BOOST_DEDUCED_TYPENAME and BOOST_UNORDERED_PAIR_CAST, it's unlikely that the compilers which require them will be able to cope with the new version of unordered. - Use the old equality algorithm if BOOST_UNORDERED_DEPRECATED_EQUALITY is defined. - Use SFINAE to control which overloads of `construct_impl` are available. Fixes problems with differing overload resolution on different compilers. - Support for piecewise pair construction. - Only support the old variadic pair construction when BOOST_UNORDERED_DEPRECATED_PAIR_CONSTRUCT is defined (also fixed some bugs). - Avoid instantiating BOOST_RV_REF for non-classes. - Support optional allocator member functions for compilers with SFINAE expressions and Visual C++ 9.0/10.0 - Follow boost macro naming conventions. - Improved portability for `allocator_traits` emulation. Current compiler support: - Full support for GCC 4.4+, Visual C++ 9.0+, Clang. - All other compilers odn't support optional allocator members. - No other errors for GCC 3.4.6+, Visual C++ 8.0, Intel, Pathscale. - Visual Age has a compile error if `select_on_container_copy_construction` isn't `const` (it should ignore it). - `select_on_container_copy_construction` detection doesn't work on Sun. - `unnecessary_copy_tests` is failling for vacpp on AIX, but not on linux. - Warnings causing failures for Visual C++ with STLport and WM5. [SVN r74234]
This commit is contained in:
@@ -52,24 +52,21 @@ namespace unordered
|
||||
private:
|
||||
#endif
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME
|
||||
::boost::unordered::detail::rebind_wrap<
|
||||
typedef typename ::boost::unordered::detail::rebind_wrap<
|
||||
allocator_type, value_type>::type
|
||||
value_allocator;
|
||||
typedef ::boost::unordered::detail::allocator_traits<value_allocator> allocator_traits;
|
||||
|
||||
typedef ::boost::unordered::detail::map<K, H, P,
|
||||
value_allocator> types;
|
||||
typedef BOOST_DEDUCED_TYPENAME types::impl table;
|
||||
typedef typename types::impl table;
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME types::node_ptr node_ptr;
|
||||
typedef typename types::node_ptr node_ptr;
|
||||
|
||||
public:
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME
|
||||
allocator_traits::pointer pointer;
|
||||
typedef BOOST_DEDUCED_TYPENAME
|
||||
allocator_traits::const_pointer const_pointer;
|
||||
typedef typename allocator_traits::pointer pointer;
|
||||
typedef typename allocator_traits::const_pointer const_pointer;
|
||||
|
||||
typedef value_type& reference;
|
||||
typedef value_type const& const_reference;
|
||||
@@ -135,9 +132,7 @@ namespace unordered
|
||||
|
||||
unordered_map(unordered_map const&);
|
||||
|
||||
#if BOOST_UNORDERED_USE_RV_REF
|
||||
unordered_map& operator=(
|
||||
BOOST_RV_REF(unordered_map) x)
|
||||
unordered_map& operator=(BOOST_RV_REF(unordered_map) x)
|
||||
{
|
||||
table_.move_assign(x.table_);
|
||||
return *this;
|
||||
@@ -147,7 +142,6 @@ namespace unordered
|
||||
: table_(other.table_, ::boost::unordered::detail::move_tag())
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
#if !defined(BOOST_NO_RVALUE_REFERENCES)
|
||||
unordered_map(unordered_map&&, allocator_type const&);
|
||||
@@ -260,11 +254,10 @@ namespace unordered
|
||||
#endif
|
||||
|
||||
std::pair<iterator, bool> insert(value_type const&);
|
||||
iterator insert(const_iterator, value_type const&);
|
||||
#if BOOST_UNORDERED_USE_RV_REF
|
||||
std::pair<iterator, bool> insert(BOOST_RV_REF(value_type));
|
||||
iterator insert(const_iterator, value_type const&);
|
||||
iterator insert(const_iterator, BOOST_RV_REF(value_type));
|
||||
#endif
|
||||
|
||||
template <class InputIt> void insert(InputIt, InputIt);
|
||||
|
||||
#if !defined(BOOST_NO_0X_HDR_INITIALIZER_LIST)
|
||||
@@ -403,8 +396,7 @@ namespace unordered
|
||||
private:
|
||||
#endif
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME
|
||||
::boost::unordered::detail::rebind_wrap<
|
||||
typedef typename ::boost::unordered::detail::rebind_wrap<
|
||||
allocator_type, value_type>::type
|
||||
value_allocator;
|
||||
typedef ::boost::unordered::detail::allocator_traits<value_allocator>
|
||||
@@ -412,16 +404,14 @@ namespace unordered
|
||||
|
||||
typedef ::boost::unordered::detail::multimap<K, H, P,
|
||||
value_allocator> types;
|
||||
typedef BOOST_DEDUCED_TYPENAME types::impl table;
|
||||
typedef typename types::impl table;
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME types::node_ptr node_ptr;
|
||||
typedef typename types::node_ptr node_ptr;
|
||||
|
||||
public:
|
||||
|
||||
typedef BOOST_DEDUCED_TYPENAME
|
||||
allocator_traits::pointer pointer;
|
||||
typedef BOOST_DEDUCED_TYPENAME
|
||||
allocator_traits::const_pointer const_pointer;
|
||||
typedef typename allocator_traits::pointer pointer;
|
||||
typedef typename allocator_traits::const_pointer const_pointer;
|
||||
|
||||
typedef value_type& reference;
|
||||
typedef value_type const& const_reference;
|
||||
@@ -487,9 +477,7 @@ namespace unordered
|
||||
|
||||
unordered_multimap(unordered_multimap const&);
|
||||
|
||||
#if BOOST_UNORDERED_USE_RV_REF
|
||||
unordered_multimap& operator=(
|
||||
BOOST_RV_REF(unordered_multimap) x)
|
||||
unordered_multimap& operator=(BOOST_RV_REF(unordered_multimap) x)
|
||||
{
|
||||
table_.move_assign(x.table_);
|
||||
return *this;
|
||||
@@ -499,7 +487,6 @@ namespace unordered
|
||||
: table_(other.table_, ::boost::unordered::detail::move_tag())
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
#if !defined(BOOST_NO_RVALUE_REFERENCES)
|
||||
unordered_multimap(unordered_multimap&&, allocator_type const&);
|
||||
@@ -612,11 +599,10 @@ namespace unordered
|
||||
#endif
|
||||
|
||||
iterator insert(value_type const&);
|
||||
iterator insert(const_iterator, value_type const&);
|
||||
#if BOOST_UNORDERED_USE_RV_REF
|
||||
iterator insert(BOOST_RV_REF(value_type));
|
||||
iterator insert(const_iterator, value_type const&);
|
||||
iterator insert(const_iterator, BOOST_RV_REF(value_type));
|
||||
#endif
|
||||
|
||||
template <class InputIt> void insert(InputIt, InputIt);
|
||||
|
||||
#if !defined(BOOST_NO_0X_HDR_INITIALIZER_LIST)
|
||||
@@ -851,16 +837,15 @@ namespace unordered
|
||||
#if defined(BOOST_UNORDERED_STD_FORWARD_MOVE)
|
||||
template <class K, class T, class H, class P, class A>
|
||||
template <class... Args>
|
||||
std::pair<BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator, bool>
|
||||
std::pair<typename unordered_map<K,T,H,P,A>::iterator, bool>
|
||||
unordered_map<K,T,H,P,A>::emplace(Args&&... args)
|
||||
{
|
||||
return BOOST_UNORDERED_PAIR_CAST(iterator, bool,
|
||||
table_.emplace(std::forward<Args>(args)...));
|
||||
return table_.emplace(std::forward<Args>(args)...);
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
template <class... Args>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator
|
||||
typename unordered_map<K,T,H,P,A>::iterator
|
||||
unordered_map<K,T,H,P,A>::emplace_hint(const_iterator, Args&&... args)
|
||||
{
|
||||
return iterator(table_.emplace(std::forward<Args>(args)...).first);
|
||||
@@ -869,18 +854,17 @@ namespace unordered
|
||||
|
||||
#if !BOOST_WORKAROUND(__SUNPRO_CC, BOOST_TESTED_AT(0x5100))
|
||||
template <class K, class T, class H, class P, class A>
|
||||
std::pair<BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator, bool>
|
||||
std::pair<typename unordered_map<K,T,H,P,A>::iterator, bool>
|
||||
unordered_map<K,T,H,P,A>::emplace(
|
||||
boost::unordered::detail::empty_emplace,
|
||||
value_type v
|
||||
)
|
||||
{
|
||||
return BOOST_UNORDERED_PAIR_CAST(iterator, bool,
|
||||
table_.emplace(boost::move(v)));
|
||||
return table_.emplace(boost::move(v));
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator
|
||||
typename unordered_map<K,T,H,P,A>::iterator
|
||||
unordered_map<K,T,H,P,A>::emplace_hint(const_iterator,
|
||||
boost::unordered::detail::empty_emplace,
|
||||
value_type v
|
||||
@@ -895,23 +879,18 @@ namespace unordered
|
||||
template < \
|
||||
BOOST_UNORDERED_TEMPLATE_ARGS(z, n) \
|
||||
> \
|
||||
std::pair< \
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator, \
|
||||
bool> \
|
||||
std::pair<typename unordered_map<K,T,H,P,A>::iterator, bool> \
|
||||
unordered_map<K,T,H,P,A>::emplace( \
|
||||
BOOST_UNORDERED_FUNCTION_PARAMS(z, n)) \
|
||||
{ \
|
||||
return \
|
||||
BOOST_UNORDERED_PAIR_CAST(iterator, bool, \
|
||||
table_.emplace( \
|
||||
BOOST_UNORDERED_CALL_PARAMS(z, n))); \
|
||||
return table_.emplace(BOOST_UNORDERED_CALL_PARAMS(z, n)); \
|
||||
} \
|
||||
\
|
||||
template <class K, class T, class H, class P, class A> \
|
||||
template < \
|
||||
BOOST_UNORDERED_TEMPLATE_ARGS(z, n) \
|
||||
> \
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator \
|
||||
typename unordered_map<K,T,H,P,A>::iterator \
|
||||
unordered_map<K,T,H,P,A>::emplace_hint( \
|
||||
const_iterator, \
|
||||
BOOST_UNORDERED_FUNCTION_PARAMS(z, n) \
|
||||
@@ -929,38 +908,34 @@ namespace unordered
|
||||
#endif
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
std::pair<BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator, bool>
|
||||
std::pair<typename unordered_map<K,T,H,P,A>::iterator, bool>
|
||||
unordered_map<K,T,H,P,A>::insert(value_type const& obj)
|
||||
{
|
||||
return BOOST_UNORDERED_PAIR_CAST(iterator, bool,
|
||||
table_.emplace(obj));
|
||||
return table_.emplace(obj);
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator
|
||||
typename unordered_map<K,T,H,P,A>::iterator
|
||||
unordered_map<K,T,H,P,A>::insert(const_iterator,
|
||||
value_type const& obj)
|
||||
{
|
||||
return iterator(table_.emplace(obj).first);
|
||||
}
|
||||
|
||||
#if BOOST_UNORDERED_USE_RV_REF
|
||||
template <class K, class T, class H, class P, class A>
|
||||
std::pair<BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator, bool>
|
||||
std::pair<typename unordered_map<K,T,H,P,A>::iterator, bool>
|
||||
unordered_map<K,T,H,P,A>::insert(BOOST_RV_REF(value_type) obj)
|
||||
{
|
||||
return BOOST_UNORDERED_PAIR_CAST(iterator, bool,
|
||||
table_.emplace(boost::move(obj)));
|
||||
return table_.emplace(boost::move(obj));
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator
|
||||
typename unordered_map<K,T,H,P,A>::iterator
|
||||
unordered_map<K,T,H,P,A>::insert(const_iterator,
|
||||
BOOST_RV_REF(value_type) obj)
|
||||
{
|
||||
return iterator(table_.emplace(boost::move(obj)).first);
|
||||
}
|
||||
#endif
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
template <class InputIt>
|
||||
@@ -979,21 +954,21 @@ namespace unordered
|
||||
#endif
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator
|
||||
typename unordered_map<K,T,H,P,A>::iterator
|
||||
unordered_map<K,T,H,P,A>::erase(const_iterator position)
|
||||
{
|
||||
return iterator(table_.erase(position.node_));
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::size_type
|
||||
typename unordered_map<K,T,H,P,A>::size_type
|
||||
unordered_map<K,T,H,P,A>::erase(const key_type& k)
|
||||
{
|
||||
return table_.erase_key(k);
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator
|
||||
typename unordered_map<K,T,H,P,A>::iterator
|
||||
unordered_map<K,T,H,P,A>::erase(
|
||||
const_iterator first, const_iterator last)
|
||||
{
|
||||
@@ -1015,35 +990,35 @@ namespace unordered
|
||||
// observers
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::hasher
|
||||
typename unordered_map<K,T,H,P,A>::hasher
|
||||
unordered_map<K,T,H,P,A>::hash_function() const
|
||||
{
|
||||
return table_.hash_function();
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::key_equal
|
||||
typename unordered_map<K,T,H,P,A>::key_equal
|
||||
unordered_map<K,T,H,P,A>::key_eq() const
|
||||
{
|
||||
return table_.key_eq();
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::mapped_type&
|
||||
typename unordered_map<K,T,H,P,A>::mapped_type&
|
||||
unordered_map<K,T,H,P,A>::operator[](const key_type &k)
|
||||
{
|
||||
return table_[k].second;
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::mapped_type&
|
||||
typename unordered_map<K,T,H,P,A>::mapped_type&
|
||||
unordered_map<K,T,H,P,A>::at(const key_type& k)
|
||||
{
|
||||
return table_.at(k).second;
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::mapped_type const&
|
||||
typename unordered_map<K,T,H,P,A>::mapped_type const&
|
||||
unordered_map<K,T,H,P,A>::at(const key_type& k) const
|
||||
{
|
||||
return table_.at(k).second;
|
||||
@@ -1052,14 +1027,14 @@ namespace unordered
|
||||
// lookup
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator
|
||||
typename unordered_map<K,T,H,P,A>::iterator
|
||||
unordered_map<K,T,H,P,A>::find(const key_type& k)
|
||||
{
|
||||
return iterator(table_.find_node(k));
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::const_iterator
|
||||
typename unordered_map<K,T,H,P,A>::const_iterator
|
||||
unordered_map<K,T,H,P,A>::find(const key_type& k) const
|
||||
{
|
||||
return const_iterator(table_.find_node(k));
|
||||
@@ -1068,7 +1043,7 @@ namespace unordered
|
||||
template <class K, class T, class H, class P, class A>
|
||||
template <class CompatibleKey, class CompatibleHash,
|
||||
class CompatiblePredicate>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator
|
||||
typename unordered_map<K,T,H,P,A>::iterator
|
||||
unordered_map<K,T,H,P,A>::find(
|
||||
CompatibleKey const& k,
|
||||
CompatibleHash const& hash,
|
||||
@@ -1080,7 +1055,7 @@ namespace unordered
|
||||
template <class K, class T, class H, class P, class A>
|
||||
template <class CompatibleKey, class CompatibleHash,
|
||||
class CompatiblePredicate>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::const_iterator
|
||||
typename unordered_map<K,T,H,P,A>::const_iterator
|
||||
unordered_map<K,T,H,P,A>::find(
|
||||
CompatibleKey const& k,
|
||||
CompatibleHash const& hash,
|
||||
@@ -1090,7 +1065,7 @@ namespace unordered
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::size_type
|
||||
typename unordered_map<K,T,H,P,A>::size_type
|
||||
unordered_map<K,T,H,P,A>::count(const key_type& k) const
|
||||
{
|
||||
return table_.count(k);
|
||||
@@ -1098,26 +1073,24 @@ namespace unordered
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
std::pair<
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator,
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::iterator>
|
||||
typename unordered_map<K,T,H,P,A>::iterator,
|
||||
typename unordered_map<K,T,H,P,A>::iterator>
|
||||
unordered_map<K,T,H,P,A>::equal_range(const key_type& k)
|
||||
{
|
||||
return BOOST_UNORDERED_PAIR_CAST(iterator, iterator,
|
||||
table_.equal_range(k));
|
||||
return table_.equal_range(k);
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
std::pair<
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::const_iterator,
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::const_iterator>
|
||||
typename unordered_map<K,T,H,P,A>::const_iterator,
|
||||
typename unordered_map<K,T,H,P,A>::const_iterator>
|
||||
unordered_map<K,T,H,P,A>::equal_range(const key_type& k) const
|
||||
{
|
||||
return BOOST_UNORDERED_PAIR_CAST(const_iterator, const_iterator,
|
||||
table_.equal_range(k));
|
||||
return table_.equal_range(k);
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_map<K,T,H,P,A>::size_type
|
||||
typename unordered_map<K,T,H,P,A>::size_type
|
||||
unordered_map<K,T,H,P,A>::bucket_size(size_type n) const
|
||||
{
|
||||
return table_.bucket_size(n);
|
||||
@@ -1293,7 +1266,7 @@ namespace unordered
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
template <class... Args>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator
|
||||
unordered_multimap<K,T,H,P,A>::emplace(Args&&... args)
|
||||
{
|
||||
return iterator(table_.emplace(std::forward<Args>(args)...));
|
||||
@@ -1301,7 +1274,7 @@ namespace unordered
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
template <class... Args>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator
|
||||
unordered_multimap<K,T,H,P,A>::emplace_hint(
|
||||
const_iterator, Args&&... args)
|
||||
{
|
||||
@@ -1312,7 +1285,7 @@ namespace unordered
|
||||
|
||||
#if !BOOST_WORKAROUND(__SUNPRO_CC, BOOST_TESTED_AT(0x5100))
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator
|
||||
unordered_multimap<K,T,H,P,A>::emplace(
|
||||
boost::unordered::detail::empty_emplace,
|
||||
value_type v
|
||||
@@ -1322,7 +1295,7 @@ namespace unordered
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator
|
||||
unordered_multimap<K,T,H,P,A>::emplace_hint(const_iterator,
|
||||
boost::unordered::detail::empty_emplace,
|
||||
value_type v
|
||||
@@ -1337,7 +1310,7 @@ namespace unordered
|
||||
template < \
|
||||
BOOST_UNORDERED_TEMPLATE_ARGS(z, n) \
|
||||
> \
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator \
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator \
|
||||
unordered_multimap<K,T,H,P,A>::emplace( \
|
||||
BOOST_UNORDERED_FUNCTION_PARAMS(z, n)) \
|
||||
{ \
|
||||
@@ -1349,7 +1322,7 @@ namespace unordered
|
||||
template < \
|
||||
BOOST_UNORDERED_TEMPLATE_ARGS(z, n) \
|
||||
> \
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator \
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator \
|
||||
unordered_multimap<K,T,H,P,A>::emplace_hint( \
|
||||
const_iterator, \
|
||||
BOOST_UNORDERED_FUNCTION_PARAMS(z, n)) \
|
||||
@@ -1366,36 +1339,34 @@ namespace unordered
|
||||
#endif
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator
|
||||
unordered_multimap<K,T,H,P,A>::insert(value_type const& obj)
|
||||
{
|
||||
return iterator(table_.emplace(obj));
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator
|
||||
unordered_multimap<K,T,H,P,A>::insert(
|
||||
const_iterator, value_type const& obj)
|
||||
{
|
||||
return iterator(table_.emplace(obj));
|
||||
}
|
||||
|
||||
#if BOOST_UNORDERED_USE_RV_REF
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator
|
||||
unordered_multimap<K,T,H,P,A>::insert(BOOST_RV_REF(value_type) obj)
|
||||
{
|
||||
return iterator(table_.emplace(boost::move(obj)));
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator
|
||||
unordered_multimap<K,T,H,P,A>::insert(
|
||||
const_iterator, BOOST_RV_REF(value_type) obj)
|
||||
{
|
||||
return iterator(table_.emplace(boost::move(obj)));
|
||||
}
|
||||
#endif
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
template <class InputIt>
|
||||
@@ -1414,21 +1385,21 @@ namespace unordered
|
||||
#endif
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator
|
||||
unordered_multimap<K,T,H,P,A>::erase(const_iterator position)
|
||||
{
|
||||
return iterator(table_.erase(position.node_));
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::size_type
|
||||
typename unordered_multimap<K,T,H,P,A>::size_type
|
||||
unordered_multimap<K,T,H,P,A>::erase(const key_type& k)
|
||||
{
|
||||
return table_.erase_key(k);
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator
|
||||
unordered_multimap<K,T,H,P,A>::erase(
|
||||
const_iterator first, const_iterator last)
|
||||
{
|
||||
@@ -1450,14 +1421,14 @@ namespace unordered
|
||||
// observers
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::hasher
|
||||
typename unordered_multimap<K,T,H,P,A>::hasher
|
||||
unordered_multimap<K,T,H,P,A>::hash_function() const
|
||||
{
|
||||
return table_.hash_function();
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::key_equal
|
||||
typename unordered_multimap<K,T,H,P,A>::key_equal
|
||||
unordered_multimap<K,T,H,P,A>::key_eq() const
|
||||
{
|
||||
return table_.key_eq();
|
||||
@@ -1466,14 +1437,14 @@ namespace unordered
|
||||
// lookup
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator
|
||||
unordered_multimap<K,T,H,P,A>::find(const key_type& k)
|
||||
{
|
||||
return iterator(table_.find_node(k));
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::const_iterator
|
||||
typename unordered_multimap<K,T,H,P,A>::const_iterator
|
||||
unordered_multimap<K,T,H,P,A>::find(const key_type& k) const
|
||||
{
|
||||
return const_iterator(table_.find_node(k));
|
||||
@@ -1482,7 +1453,7 @@ namespace unordered
|
||||
template <class K, class T, class H, class P, class A>
|
||||
template <class CompatibleKey, class CompatibleHash,
|
||||
class CompatiblePredicate>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator
|
||||
unordered_multimap<K,T,H,P,A>::find(
|
||||
CompatibleKey const& k,
|
||||
CompatibleHash const& hash,
|
||||
@@ -1494,7 +1465,7 @@ namespace unordered
|
||||
template <class K, class T, class H, class P, class A>
|
||||
template <class CompatibleKey, class CompatibleHash,
|
||||
class CompatiblePredicate>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::const_iterator
|
||||
typename unordered_multimap<K,T,H,P,A>::const_iterator
|
||||
unordered_multimap<K,T,H,P,A>::find(
|
||||
CompatibleKey const& k,
|
||||
CompatibleHash const& hash,
|
||||
@@ -1504,7 +1475,7 @@ namespace unordered
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::size_type
|
||||
typename unordered_multimap<K,T,H,P,A>::size_type
|
||||
unordered_multimap<K,T,H,P,A>::count(const key_type& k) const
|
||||
{
|
||||
return table_.count(k);
|
||||
@@ -1512,26 +1483,24 @@ namespace unordered
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
std::pair<
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator,
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::iterator>
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator,
|
||||
typename unordered_multimap<K,T,H,P,A>::iterator>
|
||||
unordered_multimap<K,T,H,P,A>::equal_range(const key_type& k)
|
||||
{
|
||||
return BOOST_UNORDERED_PAIR_CAST(iterator, iterator,
|
||||
table_.equal_range(k));
|
||||
return table_.equal_range(k);
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
std::pair<
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::const_iterator,
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::const_iterator>
|
||||
typename unordered_multimap<K,T,H,P,A>::const_iterator,
|
||||
typename unordered_multimap<K,T,H,P,A>::const_iterator>
|
||||
unordered_multimap<K,T,H,P,A>::equal_range(const key_type& k) const
|
||||
{
|
||||
return BOOST_UNORDERED_PAIR_CAST(const_iterator, const_iterator,
|
||||
table_.equal_range(k));
|
||||
return table_.equal_range(k);
|
||||
}
|
||||
|
||||
template <class K, class T, class H, class P, class A>
|
||||
BOOST_DEDUCED_TYPENAME unordered_multimap<K,T,H,P,A>::size_type
|
||||
typename unordered_multimap<K,T,H,P,A>::size_type
|
||||
unordered_multimap<K,T,H,P,A>::bucket_size(size_type n) const
|
||||
{
|
||||
return table_.bucket_size(n);
|
||||
|
||||
Reference in New Issue
Block a user