@@ -332,11 +332,7 @@ LL | let _val: NonNull<i32> = mem::uninitialized();
332332 | help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
333333 |
334334 = note: `std::ptr::NonNull<i32>` must be non-null
335- note: raw pointers must not be uninitialized (in this struct field)
336- --> $SRC_DIR/core/src/ptr/non_null.rs:LL:COL
337- |
338- LL | pointer: *const T,
339- | ^^^^^^^^^^^^^^^^^
335+ = note: raw pointers must not be uninitialized
340336
341337error: the type `(NonZeroU32, i32)` does not permit zero-initialization
342338 --> $DIR/invalid_value.rs:95:39
@@ -359,18 +355,7 @@ LL | let _val: (NonZeroU32, i32) = mem::uninitialized();
359355 | help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
360356 |
361357 = note: `std::num::NonZeroU32` must be non-null
362- note: integers must not be uninitialized (in this struct field)
363- --> $SRC_DIR/core/src/num/nonzero.rs:LL:COL
364- |
365- LL | / nonzero_integers! {
366- LL | | #[stable(feature = "nonzero", since = "1.28.0")] #[rustc_const_stable(feature = "nonzero", since = "1.28.0")] NonZeroU8(u8);
367- LL | | #[stable(feature = "nonzero", since = "1.28.0")] #[rustc_const_stable(feature = "nonzero", since = "1.28.0")] NonZeroU16(u16);
368- LL | | #[stable(feature = "nonzero", since = "1.28.0")] #[rustc_const_stable(feature = "nonzero", since = "1.28.0")] NonZeroU32(u32);
369- ... |
370- LL | | #[stable(feature = "signed_nonzero", since = "1.34.0")] #[rustc_const_stable(feature = "signed_nonzero", since = "1.34.0")] NonZeroIs...
371- LL | | }
372- | |_^
373- = note: this error originates in the macro `nonzero_integers` (in Nightly builds, run with -Z macro-backtrace for more info)
358+ = note: integers must not be uninitialized
374359
375360error: the type `*const dyn Send` does not permit zero-initialization
376361 --> $DIR/invalid_value.rs:98:37
@@ -477,18 +462,7 @@ note: `std::num::NonZeroU32` must be non-null (in this field of the only potenti
477462 |
478463LL | Banana(NonZeroU32),
479464 | ^^^^^^^^^^
480- note: integers must not be uninitialized (in this struct field)
481- --> $SRC_DIR/core/src/num/nonzero.rs:LL:COL
482- |
483- LL | / nonzero_integers! {
484- LL | | #[stable(feature = "nonzero", since = "1.28.0")] #[rustc_const_stable(feature = "nonzero", since = "1.28.0")] NonZeroU8(u8);
485- LL | | #[stable(feature = "nonzero", since = "1.28.0")] #[rustc_const_stable(feature = "nonzero", since = "1.28.0")] NonZeroU16(u16);
486- LL | | #[stable(feature = "nonzero", since = "1.28.0")] #[rustc_const_stable(feature = "nonzero", since = "1.28.0")] NonZeroU32(u32);
487- ... |
488- LL | | #[stable(feature = "signed_nonzero", since = "1.34.0")] #[rustc_const_stable(feature = "signed_nonzero", since = "1.34.0")] NonZeroIs...
489- LL | | }
490- | |_^
491- = note: this error originates in the macro `nonzero_integers` (in Nightly builds, run with -Z macro-backtrace for more info)
465+ = note: integers must not be uninitialized
492466
493467error: the type `bool` does not permit being left uninitialized
494468 --> $DIR/invalid_value.rs:112:26
@@ -688,11 +662,7 @@ LL | let _val: NonNull<i32> = MaybeUninit::uninit().assume_init();
688662 | help: use `MaybeUninit<T>` instead, and only call `assume_init` after initialization is done
689663 |
690664 = note: `std::ptr::NonNull<i32>` must be non-null
691- note: raw pointers must not be uninitialized (in this struct field)
692- --> $SRC_DIR/core/src/ptr/non_null.rs:LL:COL
693- |
694- LL | pointer: *const T,
695- | ^^^^^^^^^^^^^^^^^
665+ = note: raw pointers must not be uninitialized
696666
697667error: the type `bool` does not permit being left uninitialized
698668 --> $DIR/invalid_value.rs:159:26
0 commit comments