1 #![deny(unreachable_patterns)]
4 pub enum NonExhaustiveEnum
{
23 pub enum EmptyNonExhaustiveEnum {}
25 fn empty_non_exhaustive(x
: EmptyNonExhaustiveEnum
) {
28 _
=> {}
//~ ERROR unreachable pattern
33 match NonExhaustiveEnum
::Unit {}
34 //~^ ERROR `Unit`, `Tuple(_)` and `Struct { .. }` not covered [E0004]
35 match NormalEnum
::Unit {}
36 //~^ ERROR `Unit`, `Tuple(_)` and `Struct { .. }` not covered [E0004]