3 #![feature(never_type)]
5 // Should fake read the discriminant and throw an error
8 let c1 = || match x { };
12 // Should fake read the discriminant and throw an error
15 let c2 = || match x { _ => () };
19 // Testing single variant patterns
24 // Should fake read the discriminant and throw an error
30 SingleVariant::Points(_) => {}
36 // Should fake read the discriminant and throw an error
39 let c = || { //~ ERROR E0381
41 SingleVariant::Points(a) => {
54 match g { }; //~ ERROR E0381
56 match t { }; //~ ERROR E0381
64 // Should fake read the discriminant and throw an error
67 let c1 = || match x { };
69 //~| ERROR: non-exhaustive patterns: type `u8` is non-empty