about summary refs log tree commit diff
diff options
context:
space:
mode:
authorAda Alakbarova <ada.alakbarova@proton.me>2025-08-09 19:41:10 +0200
committerAda Alakbarova <ada.alakbarova@proton.me>2025-08-09 19:41:41 +0200
commit06e43655bc57359ece7143d5cd31afc3a0744a59 (patch)
tree1ea0bfa1307e465ef4c68846ef44054df97c5b93
parentc0a3e4802a06dd644c59aa7eed4af4bf437d3853 (diff)
`HashMap`: also add "Usage with custom key types" heading
-rw-r--r--library/std/src/collections/hash/map.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/library/std/src/collections/hash/map.rs b/library/std/src/collections/hash/map.rs
index 0c5d41bcee8..15a7a770d1a 100644
--- a/library/std/src/collections/hash/map.rs
+++ b/library/std/src/collections/hash/map.rs
@@ -169,6 +169,8 @@ use crate::ops::Index;
 /// player_stats.entry("mana").and_modify(|mana| *mana += 200).or_insert(100);
 /// ```
 ///
+/// ## Usage with custom key types
+///
 /// The easiest way to use `HashMap` with a custom key type is to derive [`Eq`] and [`Hash`].
 /// We must also derive [`PartialEq`].
 ///