blob: e0caff6a21a9d14b8571fc9455d33fa1392df024 [file]
error: Undefined Behavior: reading memory at ALLOC[0x0..0x10], but memory is uninitialized at [0x4..0x10], and this operation requires initialized memory
--> RUSTLIB/core/src/slice/cmp.rs:LL:CC
|
LL | let mut order = unsafe { compare_bytes(left, right, len) as isize };
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Undefined Behavior occurred here
|
= help: this indicates a bug in the program: it performed an invalid operation, and caused Undefined Behavior
= help: see https://doc.rust-lang.org/nightly/reference/behavior-considered-undefined.html for further information
= note: stack backtrace:
0: <u8 as core::slice::cmp::SliceOrd>::compare
at RUSTLIB/core/src/slice/cmp.rs:LL:CC
1: core::slice::cmp::cmp
at RUSTLIB/core/src/slice/cmp.rs:LL:CC
2: main
at tests/fail/uninit/uninit_alloc_diagnostic.rs:LL:CC
Uninitialized memory occurred at ALLOC[0x4..0x10], in this allocation:
ALLOC (Rust heap, size: 32, align: 8) {
0x00 41 42 43 44 __ __ __ __ __ __ __ __ __ __ __ __ ABCD░░░░░░░░░░░░
0x10 00 __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ .░░░░░░░░░░░░░░░
}
note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace
error: aborting due to 1 previous error