We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 36bb5e8 commit 54eb376Copy full SHA for 54eb376
library/core/src/mem/maybe_uninit.rs
@@ -336,9 +336,8 @@ impl<T> MaybeUninit<T> {
336
/// assert_eq!(x, (0, false));
337
/// ```
338
///
339
- /// *Incorrect* usage of this function: assuming zero filled memory is initialized,
340
- /// where some fields cannot hold 0 as a valid value, without overwriting with a
341
- /// valid bit-pattern.
+ /// *Incorrect* usage of this function: calling `x.zeroed().assume_init()`
+ /// when `0` is not a valid bit-pattern for the type:
342
343
/// ```rust,no_run
344
/// use std::mem::MaybeUninit;
0 commit comments