]> git.lizzy.rs Git - rust.git/blob - src/test/ui/variants/variant-used-as-type.rs
Rollup merge of #100112 - RalfJung:assert_send_and_sync, r=m-ou-se
[rust.git] / src / test / ui / variants / variant-used-as-type.rs
1 // Test error message when enum variants are used as types
2
3
4 // issue 21225
5 enum Ty {
6     A,
7     B(Ty::A),
8     //~^ ERROR expected type, found variant `Ty::A`
9 }
10
11
12 // issue 19197
13 enum E {
14     A
15 }
16
17 impl E::A {}
18 //~^ ERROR expected type, found variant `E::A`
19
20 fn main() {}