about summary refs log tree commit diff
diff options
context:
space:
mode:
authorScott McMurray <scottmcm@users.noreply.github.com>2021-06-08 22:07:14 -0700
committerScott McMurray <scottmcm@users.noreply.github.com>2021-06-24 01:30:48 -0700
commit63d28192daf0ac2c704f4893d81ff32e1562e3c1 (patch)
tree0459b489f558136923c3e9e28846f018ffe04c45
parenta3eb9e3db2af13cb8c8a7542ae94514228a5417c (diff)
downloadrust-63d28192daf0ac2c704f4893d81ff32e1562e3c1.tar.gz
rust-63d28192daf0ac2c704f4893d81ff32e1562e3c1.zip
Add tracking issue and rename to hash_one
-rw-r--r--library/core/src/hash/mod.rs14
1 files changed, 7 insertions, 7 deletions
diff --git a/library/core/src/hash/mod.rs b/library/core/src/hash/mod.rs
index 28f98d983c7..9dbefe0822e 100644
--- a/library/core/src/hash/mod.rs
+++ b/library/core/src/hash/mod.rs
@@ -496,7 +496,7 @@ pub trait BuildHasher {
     /// # Example
     ///
     /// ```
-    /// #![feature(build_hasher_simple_hash_of)]
+    /// #![feature(build_hasher_simple_hash_one)]
     ///
     /// use std::cmp::{max, min};
     /// use std::hash::{BuildHasher, Hash, Hasher};
@@ -511,16 +511,16 @@ pub trait BuildHasher {
     /// // Then later, in a `#[test]` for the type...
     /// let bh = std::collections::hash_map::RandomState::new();
     /// assert_eq!(
-    ///     bh.hash_of(OrderAmbivalentPair(1, 2)),
-    ///     bh.hash_of(OrderAmbivalentPair(2, 1))
+    ///     bh.hash_one(OrderAmbivalentPair(1, 2)),
+    ///     bh.hash_one(OrderAmbivalentPair(2, 1))
     /// );
     /// assert_eq!(
-    ///     bh.hash_of(OrderAmbivalentPair(10, 2)),
-    ///     bh.hash_of(&OrderAmbivalentPair(2, 10))
+    ///     bh.hash_one(OrderAmbivalentPair(10, 2)),
+    ///     bh.hash_one(&OrderAmbivalentPair(2, 10))
     /// );
     /// ```
-    #[unstable(feature = "build_hasher_simple_hash_of", issue = "88888888")]
-    fn hash_of<T: Hash>(&self, x: T) -> u64 {
+    #[unstable(feature = "build_hasher_simple_hash_one", issue = "86161")]
+    fn hash_one<T: Hash>(&self, x: T) -> u64 {
         let mut hasher = self.build_hasher();
         x.hash(&mut hasher);
         hasher.finish()