We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent be8d728 commit 6d32e5aCopy full SHA for 6d32e5a
src/libcore/mem.rs
@@ -1321,6 +1321,9 @@ impl<T> MaybeUninit<T> {
1321
/// Reads the value from the `MaybeUninit<T>` container. The resulting `T` is subject
1322
/// to the usual drop handling.
1323
///
1324
+ /// Whenever possible, it is preferrable to use [`into_initialized`] instead, which
1325
+ /// prevents duplicating the content of the `MaybeUninit<T>`.
1326
+ ///
1327
/// # Safety
1328
1329
/// It is up to the caller to guarantee that the `MaybeUninit<T>` really is in an initialized
0 commit comments