summaryrefslogtreecommitdiff
path: root/absl/container/internal/raw_hash_set.h
diff options
context:
space:
mode:
authorGravatar Abseil Team <absl-team@google.com>2020-10-14 10:45:02 -0700
committerGravatar Derek Mauro <dmauro@google.com>2020-10-14 14:52:17 -0400
commit60d00a5822bb98f18e40b294554f91ca14fb793a (patch)
treef9b37ed0aa0c79d5e0fb9b5df97bf7303b6951b0 /absl/container/internal/raw_hash_set.h
parentf3f785ab59478dd0312bf1b5df65d380650bf0dc (diff)
Export of internal Abseil changes
-- 4ee535c37f92cd45b8c9aa009e5c833265b3a0bb by Samuel Benzaquen <sbenza@google.com>: Test and fix `insert(hint, node)` PiperOrigin-RevId: 337122891 -- 7b760ced555756fecbad702fedb697424dd65167 by Abseil Team <absl-team@google.com>: Changed the minimum version of iOS and OSX for Abseil Podspec. PiperOrigin-RevId: 336926756 GitOrigin-RevId: 4ee535c37f92cd45b8c9aa009e5c833265b3a0bb Change-Id: I94e70f3342570c83b9965ca458a3f02eaa3efc0d
Diffstat (limited to 'absl/container/internal/raw_hash_set.h')
-rw-r--r--absl/container/internal/raw_hash_set.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/absl/container/internal/raw_hash_set.h b/absl/container/internal/raw_hash_set.h
index ec13a2f7..67364b75 100644
--- a/absl/container/internal/raw_hash_set.h
+++ b/absl/container/internal/raw_hash_set.h
@@ -1065,7 +1065,9 @@ class raw_hash_set {
}
iterator insert(const_iterator, node_type&& node) {
- return insert(std::move(node)).first;
+ auto res = insert(std::move(node));
+ node = std::move(res.node);
+ return res.position;
}
// This overload kicks in if we can deduce the key from args. This enables us