From e52e0d855799fe651922be4a038fe84fe9009c72 Mon Sep 17 00:00:00 2001 From: Ralf Jung Date: Sat, 24 Dec 2022 10:12:28 +0100 Subject: [PATCH] fix warnings --- .../tests/fail/stacked_borrows/drop_in_place_protector.stderr | 2 +- .../miri/tests/fail/stacked_borrows/drop_in_place_retag.stderr | 2 +- src/tools/miri/tests/pass/vec.rs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/tools/miri/tests/fail/stacked_borrows/drop_in_place_protector.stderr b/src/tools/miri/tests/fail/stacked_borrows/drop_in_place_protector.stderr index bd51a6645a6..3d0cef241c3 100644 --- a/src/tools/miri/tests/fail/stacked_borrows/drop_in_place_protector.stderr +++ b/src/tools/miri/tests/fail/stacked_borrows/drop_in_place_protector.stderr @@ -16,7 +16,7 @@ help: is this argument | LL | core::ptr::drop_in_place(x); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ - = note: BACKTRACE: + = note: BACKTRACE (of the first span): = note: inside `::drop` at $DIR/drop_in_place_protector.rs:LL:CC = note: inside `std::ptr::drop_in_place:: - shim(Some(HasDrop))` at RUSTLIB/core/src/ptr/mod.rs:LL:CC = note: inside `std::ptr::drop_in_place::<(HasDrop, u8)> - shim(Some((HasDrop, u8)))` at RUSTLIB/core/src/ptr/mod.rs:LL:CC diff --git a/src/tools/miri/tests/fail/stacked_borrows/drop_in_place_retag.stderr b/src/tools/miri/tests/fail/stacked_borrows/drop_in_place_retag.stderr index 3f9e6708bda..7f2917e7950 100644 --- a/src/tools/miri/tests/fail/stacked_borrows/drop_in_place_retag.stderr +++ b/src/tools/miri/tests/fail/stacked_borrows/drop_in_place_retag.stderr @@ -14,7 +14,7 @@ help: was created by a SharedReadOnly retag at offsets [0x0..0x1] | LL | let x = core::ptr::addr_of!(x); | ^^^^^^^^^^^^^^^^^^^^^^ - = note: BACKTRACE: + = note: BACKTRACE (of the first span): = note: inside `std::ptr::drop_in_place:: - shim(None)` at RUSTLIB/core/src/ptr/mod.rs:LL:CC note: inside `main` --> $DIR/drop_in_place_retag.rs:LL:CC diff --git a/src/tools/miri/tests/pass/vec.rs b/src/tools/miri/tests/pass/vec.rs index fb1d8e306f2..3a6655e2ba6 100644 --- a/src/tools/miri/tests/pass/vec.rs +++ b/src/tools/miri/tests/pass/vec.rs @@ -48,7 +48,7 @@ fn vec_into_iter_zst() { assert_eq!(v, 0); let mut it = vec![[0u64; 0], [0u64; 0]].into_iter(); - it.advance_by(1); + it.advance_by(1).unwrap(); drop(it); let mut it = vec![[0u64; 0], [0u64; 0]].into_iter();