Don't ICE on anonymous struct in enum variant
This commit is contained in:
parent
1bb3a9f67a
commit
35a9e73521
4 changed files with 41 additions and 1 deletions
|
@ -0,0 +1,11 @@
|
|||
#![crate_type = "lib"]
|
||||
#![feature(unnamed_fields)]
|
||||
#![allow(unused, incomplete_features)]
|
||||
|
||||
enum K {
|
||||
M {
|
||||
_ : struct { field: u8 },
|
||||
//~^ error: unnamed fields are not allowed outside of structs or unions
|
||||
//~| error: anonymous structs are not allowed outside of unnamed struct or union fields
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue