]> git.proxmox.com Git - rustc.git/blame - src/test/run-pass/never_coercions.rs
New upstream version 1.33.0+dfsg1
[rustc.git] / src / test / run-pass / never_coercions.rs
CommitLineData
5bcae85e
SL
1// Test that having something of type ! doesn't screw up type-checking and that it coerces to the
2// LUB type of the other match arms.
970d7e83 3
5bcae85e
SL
4fn main() {
5 let v: Vec<u32> = Vec::new();
6 match 0u32 {
7 0 => &v,
8 1 => return,
9 _ => &v[..],
10 };
1a4d82fc
JJ
11}
12