#![allow(dead_code, deprecated, unused_variables, unused_mut)] use std::cell::OnceCell; fn main() { let cell: OnceCell = OnceCell::new(); assert_eq!(cell.into_inner(), None); let cell = OnceCell::new(); let _ = cell.set("hello".to_owned()); assert_eq!(cell.into_inner(), Some("hello".to_owned())); }