]> git.proxmox.com Git - rustc.git/blame - src/test/mir-opt/const_goto_const_eval_fail.rs
Merge tag 'debian/1.52.1+dfsg1-1_exp2' into proxmox/buster
[rustc.git] / src / test / mir-opt / const_goto_const_eval_fail.rs
CommitLineData
6a06907d
XL
1#![feature(min_const_generics)]
2#![crate_type = "lib"]
3
4// If const eval fails, then don't crash
5// EMIT_MIR const_goto_const_eval_fail.f.ConstGoto.diff
6pub fn f<const A: i32, const B: bool>() -> u64 {
7 match {
8 match A {
9 1 | 2 | 3 => B,
10 _ => true,
11 }
12 } {
13 false => 1,
14 true => 2,
15 }
16}