diff options
| author | Sky <sky@sky9.dev> | 2024-03-19 14:28:01 -0400 |
|---|---|---|
| committer | Sky <sky@sky9.dev> | 2024-03-19 14:28:01 -0400 |
| commit | 49dd50f880aeb20b89c696acd56581808412a7ca (patch) | |
| tree | 9014b5c2bc725a09e60e66a37bca6198e71e4e90 | |
| parent | a385e5667c11098a01368c06e7c0c9236cd477cc (diff) | |
| download | rust-49dd50f880aeb20b89c696acd56581808412a7ca.tar.gz rust-49dd50f880aeb20b89c696acd56581808412a7ca.zip | |
Add "put" as a confusable for insert on hash map/set
| -rw-r--r-- | library/std/src/collections/hash/map.rs | 2 | ||||
| -rw-r--r-- | library/std/src/collections/hash/set.rs | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/library/std/src/collections/hash/map.rs b/library/std/src/collections/hash/map.rs index 627befb63a1..2cc9afe9249 100644 --- a/library/std/src/collections/hash/map.rs +++ b/library/std/src/collections/hash/map.rs @@ -1101,7 +1101,7 @@ where /// ``` #[inline] #[stable(feature = "rust1", since = "1.0.0")] - #[rustc_confusables("push", "append")] + #[rustc_confusables("push", "append", "put")] pub fn insert(&mut self, k: K, v: V) -> Option<V> { self.base.insert(k, v) } diff --git a/library/std/src/collections/hash/set.rs b/library/std/src/collections/hash/set.rs index 371201ff44c..3910100f212 100644 --- a/library/std/src/collections/hash/set.rs +++ b/library/std/src/collections/hash/set.rs @@ -885,7 +885,7 @@ where /// ``` #[inline] #[stable(feature = "rust1", since = "1.0.0")] - #[rustc_confusables("push", "append")] + #[rustc_confusables("push", "append", "put")] pub fn insert(&mut self, value: T) -> bool { self.base.insert(value) } |
