Skip to content

Commit 50b0fa7

Browse files
committed
Silence warning in miri tests.
1 parent 7a721fd commit 50b0fa7

File tree

3 files changed

+3
-0
lines changed

3 files changed

+3
-0
lines changed

src/tools/miri/tests/fail/function_calls/arg_inplace_observe_after.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ fn main() {
2222
}
2323
}
2424

25+
#[expect(unused_variables, unused_assignments)]
2526
pub fn change_arg(mut x: S) {
2627
x.0 = 0;
2728
}

src/tools/miri/tests/fail/function_calls/arg_inplace_observe_during.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ fn main() {
2323
}
2424
}
2525

26+
#[expect(unused_variables, unused_assignments)]
2627
pub fn change_arg(mut x: S, ptr: *mut S) {
2728
x.0 = 0;
2829
// If `x` got passed in-place, we'd see the write through `ptr`!

src/tools/miri/tests/pass/align_repeat_into_well_aligned_array.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
use std::mem::size_of;
44

5+
#[expect(unused_variables, unused_assignments)]
56
fn main() {
67
let mut a = Params::new();
78
// The array itself here happens to be quite well-aligned, but not all its elements have that

0 commit comments

Comments
 (0)