mirror of
https://github.com/rust-lang/rust.git
synced 2025-02-06 20:13:42 +00:00
Rollup merge of #125647 - tspiteri:track-lazy_cell_consume, r=workingjubilee
update tracking issue for lazy_cell_consume <!-- If this PR is related to an unstable feature or an otherwise tracked effort, please link to the relevant tracking issue here. If you don't know of a related tracking issue or there are none, feel free to ignore this. This PR will get automatically assigned to a reviewer. In case you would like a specific user to review your work, you can assign it to them by using r? <reviewer name> -->
This commit is contained in:
commit
4aaf9f645e
@ -78,7 +78,7 @@ impl<T, F: FnOnce() -> T> LazyCell<T, F> {
|
||||
/// assert_eq!(&*lazy, "HELLO, WORLD!");
|
||||
/// assert_eq!(LazyCell::into_inner(lazy).ok(), Some("HELLO, WORLD!".to_string()));
|
||||
/// ```
|
||||
#[unstable(feature = "lazy_cell_consume", issue = "109736")]
|
||||
#[unstable(feature = "lazy_cell_consume", issue = "125623")]
|
||||
pub fn into_inner(this: Self) -> Result<T, F> {
|
||||
match this.state.into_inner() {
|
||||
State::Init(data) => Ok(data),
|
||||
|
@ -126,7 +126,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 = "109736")]
|
||||
#[unstable(feature = "lazy_cell_consume", issue = "125623")]
|
||||
pub fn into_inner(mut this: Self) -> Result<T, F> {
|
||||
let state = this.once.state();
|
||||
match state {
|
||||
|
Loading…
Reference in New Issue
Block a user