about summary refs log tree commit diff
path: root/library/std/src
diff options
context:
space:
mode:
authorTrevor Gross <tmgross@umich.edu>2024-07-11 03:16:45 -0400
committerTrevor Gross <tmgross@umich.edu>2024-07-11 03:16:45 -0400
commitab56fe20533d843b0ad29e969c67e3e0f9c588bf (patch)
tree74a24c864da9ecbce1d4e7ac5e26a55a01077969 /library/std/src
parent8c39ac9eccdfaeff11bd3b6107817a81fe0a3a43 (diff)
downloadrust-ab56fe20533d843b0ad29e969c67e3e0f9c588bf.tar.gz
rust-ab56fe20533d843b0ad29e969c67e3e0f9c588bf.zip
Rename `lazy_cell_consume` to `lazy_cell_into_inner`
Name this something that is less confusable with an atomic consume API for
`{Lazy,Once}Lock`.
Diffstat (limited to 'library/std/src')
-rw-r--r--library/std/src/sync/lazy_lock.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/library/std/src/sync/lazy_lock.rs b/library/std/src/sync/lazy_lock.rs
index b70c041fa42..18906aceffa 100644
--- a/library/std/src/sync/lazy_lock.rs
+++ b/library/std/src/sync/lazy_lock.rs
@@ -107,7 +107,7 @@ impl<T, F: FnOnce() -> T> LazyLock<T, F> {
     /// # Examples
     ///
     /// ```
-    /// #![feature(lazy_cell_consume)]
+    /// #![feature(lazy_cell_into_inner)]
     ///
     /// use std::sync::LazyLock;
     ///
@@ -118,7 +118,7 @@ impl<T, F: FnOnce() -> T> LazyLock<T, F> {
     /// assert_eq!(&*lazy, "HELLO, WORLD!");
     /// assert_eq!(LazyLock::into_inner(lazy).ok(), Some("HELLO, WORLD!".to_string()));
     /// ```
-    #[unstable(feature = "lazy_cell_consume", issue = "125623")]
+    #[unstable(feature = "lazy_cell_into_inner", issue = "125623")]
     pub fn into_inner(mut this: Self) -> Result<T, F> {
         let state = this.once.state();
         match state {