summaryrefslogtreecommitdiff
path: root/absl/container/flat_hash_set.h
diff options
context:
space:
mode:
authorGravatar Evan Brown <ezb@google.com>2022-09-28 10:44:11 -0700
committerGravatar Copybara-Service <copybara-worker@google.com>2022-09-28 10:44:49 -0700
commit6d9ea2b46f470406e1f49acc30b272c6e9f6cc5e (patch)
tree06b005eae4626884acab33c51351dd1b62eac2a0 /absl/container/flat_hash_set.h
parentdf19c209961b44299aa047d7db0d3972d94a2d0b (diff)
Add common_policy_traits - a subset of hash_policy_traits that can be shared between raw_hash_set and btree.
Also remove the transfer implementations from btree_set.h and flat_hash_set.h, which are equivalent to the default implementations. Motivation: this will simplify upcoming changes related to trivial relocation. PiperOrigin-RevId: 477493403 Change-Id: I75babef4c93dec3a8105f86c58af54199bb1ec9c
Diffstat (limited to 'absl/container/flat_hash_set.h')
-rw-r--r--absl/container/flat_hash_set.h7
1 files changed, 0 insertions, 7 deletions
diff --git a/absl/container/flat_hash_set.h b/absl/container/flat_hash_set.h
index 4938c703..f5376f99 100644
--- a/absl/container/flat_hash_set.h
+++ b/absl/container/flat_hash_set.h
@@ -474,13 +474,6 @@ struct FlatHashSetPolicy {
absl::allocator_traits<Allocator>::destroy(*alloc, slot);
}
- template <class Allocator>
- static void transfer(Allocator* alloc, slot_type* new_slot,
- slot_type* old_slot) {
- construct(alloc, new_slot, std::move(*old_slot));
- destroy(alloc, old_slot);
- }
-
static T& element(slot_type* slot) { return *slot; }
template <class F, class... Args>