Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 83339bf

Browse files
committedJan 24, 2025··
add a regression test
1 parent af2ce8b commit 83339bf

File tree

2 files changed

+14
-6
lines changed

2 files changed

+14
-6
lines changed
 

‎tests/crashes/128097.rs

Lines changed: 0 additions & 6 deletions
This file was deleted.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
// regression test for <https://github.com/rust-lang/rust/issues/112788>.
2+
// this test used to ICE because we tried to run drop glue of `x`
3+
// if dropping `_y` (happening at the `become` site) panicked and caused an unwind.
4+
//
5+
//@ check-pass
6+
#![expect(incomplete_features)]
7+
#![feature(explicit_tail_calls)]
8+
9+
fn f(x: &mut ()) {
10+
let _y = String::new();
11+
become f(x);
12+
}
13+
14+
fn main() {}

0 commit comments

Comments
 (0)
Please sign in to comment.