Skip to content

Commit 5bc36e5

Browse files
committed
bless miri test
1 parent eb41f06 commit 5bc36e5

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

Diff for: src/tools/miri/tests/fail/alloc/global_system_mixup.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@
44

55
//@normalize-stderr-test: "using [A-Za-z]+ heap deallocation operation" -> "using PLATFORM heap deallocation operation"
66
//@normalize-stderr-test: "\| +\^+" -> "| ^"
7-
//@normalize-stderr-test: "libc::free\([^()]*\)|unsafe \{ HeapFree\([^}]*\};" -> "FREE();"
7+
//@normalize-stderr-test: "unsafe \{ libc::free\([^()]*\) \}|unsafe \{ HeapFree\([^}]*\};" -> "FREE();"
8+
//@normalize-stderr-test: "alloc::[A-Za-z]+::" -> "alloc::PLATFORM::"
9+
//@normalize-stderr-test: "alloc/[A-Za-z]+.rs" -> "alloc/PLATFORM.rs"
810

911
#![feature(allocator_api, slice_ptr_get)]
1012

Diff for: src/tools/miri/tests/fail/alloc/global_system_mixup.stderr

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
error: Undefined Behavior: deallocating ALLOC, which is Rust heap memory, using PLATFORM heap deallocation operation
2-
--> RUSTLIB/std/src/sys/pal/PLATFORM/alloc.rs:LL:CC
2+
--> RUSTLIB/std/src/sys/alloc/PLATFORM.rs:LL:CC
33
|
44
LL | FREE();
55
| ^ deallocating ALLOC, which is Rust heap memory, using PLATFORM heap deallocation operation
66
|
77
= help: this indicates a bug in the program: it performed an invalid operation, and caused Undefined Behavior
88
= help: see https://doc.rust-lang.org/nightly/reference/behavior-considered-undefined.html for further information
99
= note: BACKTRACE:
10-
= note: inside `std::sys::pal::PLATFORM::alloc::<impl std::alloc::GlobalAlloc for std::alloc::System>::dealloc` at RUSTLIB/std/src/sys/pal/PLATFORM/alloc.rs:LL:CC
10+
= note: inside `std::sys::alloc::PLATFORM::<impl std::alloc::GlobalAlloc for std::alloc::System>::dealloc` at RUSTLIB/std/src/sys/alloc/PLATFORM.rs:LL:CC
1111
= note: inside `<std::alloc::System as std::alloc::Allocator>::deallocate` at RUSTLIB/std/src/alloc.rs:LL:CC
1212
note: inside `main`
1313
--> $DIR/global_system_mixup.rs:LL:CC

0 commit comments

Comments
 (0)