Skip to content

Commit 3327053

Browse files
committed
bless miri abort tests
1 parent c078244 commit 3327053

File tree

9 files changed

+25
-17
lines changed

9 files changed

+25
-17
lines changed

library/std/src/sys/pal/windows/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -356,7 +356,7 @@ pub fn abort_internal() -> ! {
356356

357357
#[cfg(miri)]
358358
pub fn abort_internal() -> ! {
359-
crate::intrinsics::abort();
359+
crate::intrinsics::abort()
360360
}
361361

362362
/// Align the inner value to 8 bytes.

src/tools/miri/tests/fail/panic/panic_abort1.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//@error-in-other-file: the program aborted execution
22
//@normalize-stderr-test: "\| +\^+" -> "| ^"
3-
//@normalize-stderr-test: "unsafe \{ libc::abort\(\); \}|core::intrinsics::abort\(\);" -> "ABORT();"
3+
//@normalize-stderr-test: "unsafe \{ libc::abort\(\) \}|core::intrinsics::abort\(\)" -> "ABORT()"
44
//@compile-flags: -C panic=abort
55

66
fn main() {

src/tools/miri/tests/fail/panic/panic_abort1.stderr

+5-3
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,15 @@ panicking from libstd
44
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
55
note: in Miri, you may have to set `MIRIFLAGS=-Zmiri-env-forward=RUST_BACKTRACE` for the environment variable to have an effect
66
error: abnormal termination: the program aborted execution
7-
--> RUSTLIB/panic_abort/src/lib.rs:LL:CC
7+
--> RUSTLIB/std/src/sys/pal/PLATFORM/mod.rs:LL:CC
88
|
9-
LL | ABORT();
9+
LL | ABORT()
1010
| ^ the program aborted execution
1111
|
1212
= note: BACKTRACE:
13-
= note: inside `panic_abort::__rust_start_panic::abort` at RUSTLIB/panic_abort/src/lib.rs:LL:CC
13+
= note: inside `std::sys::pal::PLATFORM::abort_internal` at RUSTLIB/std/src/sys/pal/PLATFORM/mod.rs:LL:CC
14+
= note: inside `std::process::abort` at RUSTLIB/std/src/process.rs:LL:CC
15+
= note: inside `std::rt::__rust_abort` at RUSTLIB/std/src/rt.rs:LL:CC
1416
= note: inside `panic_abort::__rust_start_panic` at RUSTLIB/panic_abort/src/lib.rs:LL:CC
1517
= note: inside `std::panicking::rust_panic` at RUSTLIB/std/src/panicking.rs:LL:CC
1618
= note: inside `std::panicking::rust_panic_with_hook` at RUSTLIB/std/src/panicking.rs:LL:CC

src/tools/miri/tests/fail/panic/panic_abort2.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//@error-in-other-file: the program aborted execution
22
//@normalize-stderr-test: "\| +\^+" -> "| ^"
3-
//@normalize-stderr-test: "unsafe \{ libc::abort\(\); \}|core::intrinsics::abort\(\);" -> "ABORT();"
3+
//@normalize-stderr-test: "unsafe \{ libc::abort\(\) \}|core::intrinsics::abort\(\)" -> "ABORT()"
44
//@compile-flags: -C panic=abort
55

66
fn main() {

src/tools/miri/tests/fail/panic/panic_abort2.stderr

+5-3
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,15 @@ thread 'main' panicked at tests/fail/panic/panic_abort2.rs:LL:CC:
44
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
55
note: in Miri, you may have to set `MIRIFLAGS=-Zmiri-env-forward=RUST_BACKTRACE` for the environment variable to have an effect
66
error: abnormal termination: the program aborted execution
7-
--> RUSTLIB/panic_abort/src/lib.rs:LL:CC
7+
--> RUSTLIB/std/src/sys/pal/PLATFORM/mod.rs:LL:CC
88
|
9-
LL | ABORT();
9+
LL | ABORT()
1010
| ^ the program aborted execution
1111
|
1212
= note: BACKTRACE:
13-
= note: inside `panic_abort::__rust_start_panic::abort` at RUSTLIB/panic_abort/src/lib.rs:LL:CC
13+
= note: inside `std::sys::pal::PLATFORM::abort_internal` at RUSTLIB/std/src/sys/pal/PLATFORM/mod.rs:LL:CC
14+
= note: inside `std::process::abort` at RUSTLIB/std/src/process.rs:LL:CC
15+
= note: inside `std::rt::__rust_abort` at RUSTLIB/std/src/rt.rs:LL:CC
1416
= note: inside `panic_abort::__rust_start_panic` at RUSTLIB/panic_abort/src/lib.rs:LL:CC
1517
= note: inside `std::panicking::rust_panic` at RUSTLIB/std/src/panicking.rs:LL:CC
1618
= note: inside `std::panicking::rust_panic_with_hook` at RUSTLIB/std/src/panicking.rs:LL:CC

src/tools/miri/tests/fail/panic/panic_abort3.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//@error-in-other-file: the program aborted execution
22
//@normalize-stderr-test: "\| +\^+" -> "| ^"
3-
//@normalize-stderr-test: "unsafe \{ libc::abort\(\); \}|core::intrinsics::abort\(\);" -> "ABORT();"
3+
//@normalize-stderr-test: "unsafe \{ libc::abort\(\) \}|core::intrinsics::abort\(\)" -> "ABORT()"
44
//@compile-flags: -C panic=abort
55

66
fn main() {

src/tools/miri/tests/fail/panic/panic_abort3.stderr

+5-3
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,15 @@ panicking from libcore
44
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
55
note: in Miri, you may have to set `MIRIFLAGS=-Zmiri-env-forward=RUST_BACKTRACE` for the environment variable to have an effect
66
error: abnormal termination: the program aborted execution
7-
--> RUSTLIB/panic_abort/src/lib.rs:LL:CC
7+
--> RUSTLIB/std/src/sys/pal/PLATFORM/mod.rs:LL:CC
88
|
9-
LL | ABORT();
9+
LL | ABORT()
1010
| ^ the program aborted execution
1111
|
1212
= note: BACKTRACE:
13-
= note: inside `panic_abort::__rust_start_panic::abort` at RUSTLIB/panic_abort/src/lib.rs:LL:CC
13+
= note: inside `std::sys::pal::PLATFORM::abort_internal` at RUSTLIB/std/src/sys/pal/PLATFORM/mod.rs:LL:CC
14+
= note: inside `std::process::abort` at RUSTLIB/std/src/process.rs:LL:CC
15+
= note: inside `std::rt::__rust_abort` at RUSTLIB/std/src/rt.rs:LL:CC
1416
= note: inside `panic_abort::__rust_start_panic` at RUSTLIB/panic_abort/src/lib.rs:LL:CC
1517
= note: inside `std::panicking::rust_panic` at RUSTLIB/std/src/panicking.rs:LL:CC
1618
= note: inside `std::panicking::rust_panic_with_hook` at RUSTLIB/std/src/panicking.rs:LL:CC

src/tools/miri/tests/fail/panic/panic_abort4.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//@error-in-other-file: the program aborted execution
22
//@normalize-stderr-test: "\| +\^+" -> "| ^"
3-
//@normalize-stderr-test: "unsafe \{ libc::abort\(\); \}|core::intrinsics::abort\(\);" -> "ABORT();"
3+
//@normalize-stderr-test: "unsafe \{ libc::abort\(\) \}|core::intrinsics::abort\(\)" -> "ABORT()"
44
//@compile-flags: -C panic=abort
55

66
fn main() {

src/tools/miri/tests/fail/panic/panic_abort4.stderr

+5-3
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,15 @@ thread 'main' panicked at tests/fail/panic/panic_abort4.rs:LL:CC:
44
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
55
note: in Miri, you may have to set `MIRIFLAGS=-Zmiri-env-forward=RUST_BACKTRACE` for the environment variable to have an effect
66
error: abnormal termination: the program aborted execution
7-
--> RUSTLIB/panic_abort/src/lib.rs:LL:CC
7+
--> RUSTLIB/std/src/sys/pal/PLATFORM/mod.rs:LL:CC
88
|
9-
LL | ABORT();
9+
LL | ABORT()
1010
| ^ the program aborted execution
1111
|
1212
= note: BACKTRACE:
13-
= note: inside `panic_abort::__rust_start_panic::abort` at RUSTLIB/panic_abort/src/lib.rs:LL:CC
13+
= note: inside `std::sys::pal::PLATFORM::abort_internal` at RUSTLIB/std/src/sys/pal/PLATFORM/mod.rs:LL:CC
14+
= note: inside `std::process::abort` at RUSTLIB/std/src/process.rs:LL:CC
15+
= note: inside `std::rt::__rust_abort` at RUSTLIB/std/src/rt.rs:LL:CC
1416
= note: inside `panic_abort::__rust_start_panic` at RUSTLIB/panic_abort/src/lib.rs:LL:CC
1517
= note: inside `std::panicking::rust_panic` at RUSTLIB/std/src/panicking.rs:LL:CC
1618
= note: inside `std::panicking::rust_panic_with_hook` at RUSTLIB/std/src/panicking.rs:LL:CC

0 commit comments

Comments
 (0)