File tree Expand file tree Collapse file tree 2 files changed +8
-5
lines changed Expand file tree Collapse file tree 2 files changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -12,13 +12,13 @@ impl Drop for Foo {
1212
1313#[ inline( always) ]
1414fn has_cleanup ( ) {
15+ //~^ ERROR: panic in a function that cannot unwind
1516 let _f = Foo ;
1617 panic ! ( ) ;
1718}
1819
1920extern "C" fn panic_abort ( ) {
2021 has_cleanup ( ) ;
21- //~^ ERROR: panic in a function that cannot unwind
2222}
2323
2424fn main ( ) {
Original file line number Diff line number Diff line change @@ -6,15 +6,18 @@ error: abnormal termination: panic in a function that cannot unwind
66 --> $DIR/terminate-terminator.rs:LL:CC
77 |
88LL | / fn has_cleanup() {
9+ LL | |
910LL | | let _f = Foo;
1011LL | | panic!();
1112LL | | }
1213 | |_^ panic in a function that cannot unwind
13- ...
14- LL | has_cleanup();
15- | ------------- in this inlined function call
1614 |
17- = note: inside `panic_abort` at $DIR/terminate-terminator.rs:LL:CC
15+ = note: inside `has_cleanup` at $DIR/terminate-terminator.rs:LL:CC
16+ note: inside `panic_abort`
17+ --> $DIR/terminate-terminator.rs:LL:CC
18+ |
19+ LL | has_cleanup();
20+ | ^^^^^^^^^^^^^
1821note: inside `main`
1922 --> $DIR/terminate-terminator.rs:LL:CC
2023 |
You can’t perform that action at this time.
0 commit comments