about summary refs log tree commit diff
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2023-05-27 09:47:42 +0000
committerbors <bors@rust-lang.org>2023-05-27 09:47:42 +0000
commit786178b2ab79ae471c5efc4e1faa0c83b9151703 (patch)
tree760bce6ca3b66f3d5d71a5d7107701213c3c5208
parenta525c7ddba5997b132efa46515e0ce90c173f480 (diff)
parentba5a3968b8ecd578247f94c6a62bfa8652cc2ef8 (diff)
downloadrust-786178b2ab79ae471c5efc4e1faa0c83b9151703.tar.gz
rust-786178b2ab79ae471c5efc4e1faa0c83b9151703.zip
Auto merge of #111934 - scottmcm:stabilize-hash-one, r=Amanieu
Stabilize `BuildHasher::hash_one`

FCP completed in https://github.com/rust-lang/rust/issues/86161#issuecomment-1561125732
-rw-r--r--library/alloc/src/vec/mod.rs1
-rw-r--r--library/core/src/array/mod.rs1
-rw-r--r--library/core/src/hash/mod.rs4
3 files changed, 1 insertions, 5 deletions
diff --git a/library/alloc/src/vec/mod.rs b/library/alloc/src/vec/mod.rs
index 82f30a26d41..47661a3d384 100644
--- a/library/alloc/src/vec/mod.rs
+++ b/library/alloc/src/vec/mod.rs
@@ -2662,7 +2662,6 @@ impl<T: Clone, A: Allocator + Clone> Clone for Vec<T, A> {
 /// as required by the `core::borrow::Borrow` implementation.
 ///
 /// ```
-/// #![feature(build_hasher_simple_hash_one)]
 /// use std::hash::BuildHasher;
 ///
 /// let b = std::collections::hash_map::RandomState::new();
diff --git a/library/core/src/array/mod.rs b/library/core/src/array/mod.rs
index bdb4c975909..70f4bf2a7ed 100644
--- a/library/core/src/array/mod.rs
+++ b/library/core/src/array/mod.rs
@@ -291,7 +291,6 @@ impl<'a, T, const N: usize> TryFrom<&'a mut [T]> for &'a mut [T; N] {
 /// as required by the `Borrow` implementation.
 ///
 /// ```
-/// #![feature(build_hasher_simple_hash_one)]
 /// use std::hash::BuildHasher;
 ///
 /// let b = std::collections::hash_map::RandomState::new();
diff --git a/library/core/src/hash/mod.rs b/library/core/src/hash/mod.rs
index a73b5b610a4..ca7c0772de8 100644
--- a/library/core/src/hash/mod.rs
+++ b/library/core/src/hash/mod.rs
@@ -674,8 +674,6 @@ pub trait BuildHasher {
     /// # Example
     ///
     /// ```
-    /// #![feature(build_hasher_simple_hash_one)]
-    ///
     /// use std::cmp::{max, min};
     /// use std::hash::{BuildHasher, Hash, Hasher};
     /// struct OrderAmbivalentPair<T: Ord>(T, T);
@@ -697,7 +695,7 @@ pub trait BuildHasher {
     ///     bh.hash_one(&OrderAmbivalentPair(2, 10))
     /// );
     /// ```
-    #[unstable(feature = "build_hasher_simple_hash_one", issue = "86161")]
+    #[stable(feature = "build_hasher_simple_hash_one", since = "CURRENT_RUSTC_VERSION")]
     fn hash_one<T: Hash>(&self, x: T) -> u64
     where
         Self: Sized,