]> git.proxmox.com Git - rustc.git/blob - tests/ui/match/expr-match-panic-fn.rs
New upstream version 1.68.2+dfsg1
[rustc.git] / tests / ui / match / expr-match-panic-fn.rs
1 // run-fail
2 // error-pattern:explicit panic
3 // ignore-emscripten no processes
4
5 fn f() -> ! {
6 panic!()
7 }
8
9 fn g() -> isize {
10 let x = match true {
11 true => f(),
12 false => 10,
13 };
14 return x;
15 }
16
17 fn main() {
18 g();
19 }