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 {
12
12
13
13
#[ inline( always) ]
14
14
fn has_cleanup ( ) {
15
+ //~^ ERROR: panic in a function that cannot unwind
15
16
let _f = Foo ;
16
17
panic ! ( ) ;
17
18
}
18
19
19
20
extern "C" fn panic_abort ( ) {
20
21
has_cleanup ( ) ;
21
- //~^ ERROR: panic in a function that cannot unwind
22
22
}
23
23
24
24
fn 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
6
6
--> $DIR/terminate-terminator.rs:LL:CC
7
7
|
8
8
LL | / fn has_cleanup() {
9
+ LL | |
9
10
LL | | let _f = Foo;
10
11
LL | | panic!();
11
12
LL | | }
12
13
| |_^ panic in a function that cannot unwind
13
- ...
14
- LL | has_cleanup();
15
- | ------------- in this inlined function call
16
14
|
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
+ | ^^^^^^^^^^^^^
18
21
note: inside `main`
19
22
--> $DIR/terminate-terminator.rs:LL:CC
20
23
|
You can’t perform that action at this time.
0 commit comments