1 // Can't use unit struct as tuple struct pattern
3 // aux-build:empty-struct.rs
5 extern crate empty_struct;
18 let xe4 = XE::XEmpty4;
21 Empty2() => () //~ ERROR expected tuple struct or tuple variant, found unit struct `Empty2`
25 //~^ ERROR expected tuple struct or tuple variant, found unit struct `XEmpty2`
29 //~^ ERROR expected tuple struct or tuple variant, found unit struct `Empty2`
33 //~^ ERROR expected tuple struct or tuple variant, found unit struct `XEmpty2`
38 //~^ ERROR expected tuple struct or tuple variant, found unit variant `E::Empty4`
42 //~^ ERROR expected tuple struct or tuple variant, found unit variant `XE::XEmpty4`
47 //~^ ERROR expected tuple struct or tuple variant, found unit variant `E::Empty4`
50 XE::XEmpty4(..) => (),
51 //~^ ERROR expected tuple struct or tuple variant, found unit variant `XE::XEmpty4`