summaryrefslogtreecommitdiffstats
path: root/tests/ui/cast/issue-88621.rs
blob: 1679793ee6834e0404fad5e3ee7d37dd9eb92a2f (plain)
1
2
3
4
5
6
7
8
9
10
11
#[repr(u8)]
enum Kind2 {
    Foo() = 1,
    Bar{} = 2,
    Baz = 3,
}

fn main() {
    let _ = Kind2::Foo() as u8;
    //~^ ERROR non-primitive cast
}