mirror of
https://github.com/boostorg/unordered.git
synced 2025-07-30 03:17:15 +02:00
Rename some copy/assign/move methods
But with a hack so that the static casts will work until there's a better method.
This commit is contained in:
@ -4146,7 +4146,12 @@ struct table_unique : boost::unordered::detail::table<Types>
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// fill_buckets_unique
|
||||
|
||||
void copy_buckets(table const& src)
|
||||
BOOST_FORCEINLINE void copy_buckets(table const& src)
|
||||
{
|
||||
this->copy_buckets_unique(src);
|
||||
}
|
||||
|
||||
void copy_buckets_unique(table const& src)
|
||||
{
|
||||
this->create_buckets(this->bucket_count_);
|
||||
|
||||
@ -4170,7 +4175,12 @@ struct table_unique : boost::unordered::detail::table<Types>
|
||||
}
|
||||
}
|
||||
|
||||
void assign_buckets(table const& src)
|
||||
BOOST_FORCEINLINE void assign_buckets(table const& src)
|
||||
{
|
||||
this->assign_buckets_unique(src);
|
||||
}
|
||||
|
||||
void assign_buckets_unique(table const& src)
|
||||
{
|
||||
node_holder<node_allocator> holder(*this);
|
||||
for (node_pointer n = src.begin(); n; n = node_algo::next_node(n)) {
|
||||
@ -4178,7 +4188,12 @@ struct table_unique : boost::unordered::detail::table<Types>
|
||||
}
|
||||
}
|
||||
|
||||
void move_assign_buckets(table& src)
|
||||
BOOST_FORCEINLINE void move_assign_buckets(table const& src)
|
||||
{
|
||||
this->move_assign_buckets_unique(src);
|
||||
}
|
||||
|
||||
void move_assign_buckets_unique(table& src)
|
||||
{
|
||||
node_holder<node_allocator> holder(*this);
|
||||
for (node_pointer n = src.begin(); n; n = node_algo::next_node(n)) {
|
||||
@ -4788,7 +4803,12 @@ struct table_equiv : boost::unordered::detail::table<Types>
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// fill_buckets
|
||||
|
||||
void copy_buckets(table const& src)
|
||||
BOOST_FORCEINLINE void copy_buckets(table const& src)
|
||||
{
|
||||
this->copy_buckets_equiv(src);
|
||||
}
|
||||
|
||||
void copy_buckets_equiv(table const& src)
|
||||
{
|
||||
this->create_buckets(this->bucket_count_);
|
||||
|
||||
@ -4830,7 +4850,12 @@ struct table_equiv : boost::unordered::detail::table<Types>
|
||||
}
|
||||
}
|
||||
|
||||
void assign_buckets(table const& src)
|
||||
BOOST_FORCEINLINE void assign_buckets(table const& src)
|
||||
{
|
||||
this->assign_buckets_equiv(src);
|
||||
}
|
||||
|
||||
void assign_buckets_equiv(table const& src)
|
||||
{
|
||||
node_holder<node_allocator> holder(*this);
|
||||
for (node_pointer n = src.begin(); n;) {
|
||||
@ -4845,7 +4870,12 @@ struct table_equiv : boost::unordered::detail::table<Types>
|
||||
}
|
||||
}
|
||||
|
||||
void move_assign_buckets(table& src)
|
||||
BOOST_FORCEINLINE void move_assign_buckets(table const& src)
|
||||
{
|
||||
this->move_assign_buckets_equiv(src);
|
||||
}
|
||||
|
||||
void move_assign_buckets_equiv(table& src)
|
||||
{
|
||||
node_holder<node_allocator> holder(*this);
|
||||
for (node_pointer n = src.begin(); n;) {
|
||||
|
@ -1381,7 +1381,7 @@ unordered_map<K, T, H, P, A>::unordered_map(unordered_map const& other)
|
||||
: table_(other.table_)
|
||||
{
|
||||
if (other.table_.size_) {
|
||||
table_.copy_buckets(other.table_);
|
||||
table_.copy_buckets_unique(other.table_);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1398,7 +1398,7 @@ unordered_map<K, T, H, P, A>::unordered_map(
|
||||
: table_(other.table_, a)
|
||||
{
|
||||
if (other.table_.size_) {
|
||||
table_.copy_buckets(other.table_);
|
||||
table_.copy_buckets_unique(other.table_);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1869,7 +1869,7 @@ unordered_multimap<K, T, H, P, A>::unordered_multimap(
|
||||
: table_(other.table_)
|
||||
{
|
||||
if (other.table_.size_) {
|
||||
table_.copy_buckets(other.table_);
|
||||
table_.copy_buckets_equiv(other.table_);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1886,7 +1886,7 @@ unordered_multimap<K, T, H, P, A>::unordered_multimap(
|
||||
: table_(other.table_, a)
|
||||
{
|
||||
if (other.table_.size_) {
|
||||
table_.copy_buckets(other.table_);
|
||||
table_.copy_buckets_equiv(other.table_);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1080,7 +1080,7 @@ unordered_set<T, H, P, A>::unordered_set(unordered_set const& other)
|
||||
: table_(other.table_)
|
||||
{
|
||||
if (other.table_.size_) {
|
||||
table_.copy_buckets(other.table_);
|
||||
table_.copy_buckets_unique(other.table_);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1097,7 +1097,7 @@ unordered_set<T, H, P, A>::unordered_set(
|
||||
: table_(other.table_, a)
|
||||
{
|
||||
if (other.table_.size_) {
|
||||
table_.copy_buckets(other.table_);
|
||||
table_.copy_buckets_unique(other.table_);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1483,7 +1483,7 @@ unordered_multiset<T, H, P, A>::unordered_multiset(
|
||||
: table_(other.table_)
|
||||
{
|
||||
if (other.table_.size_) {
|
||||
table_.copy_buckets(other.table_);
|
||||
table_.copy_buckets_equiv(other.table_);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1500,7 +1500,7 @@ unordered_multiset<T, H, P, A>::unordered_multiset(
|
||||
: table_(other.table_, a)
|
||||
{
|
||||
if (other.table_.size_) {
|
||||
table_.copy_buckets(other.table_);
|
||||
table_.copy_buckets_equiv(other.table_);
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user