mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-01 15:50:05 +03:00
1ff4a1259d
Don't do pointer arithmetic on pointers to deallocated memory vec::Splice can invalidate the slice::Iter inside vec::Drain. So we replace them with dangling pointers which, unlike ones to deallocated memory, are allowed. Fixes miri test failures. Fixes https://github.com/rust-lang/miri/issues/2759