about summary refs log tree commit diff
path: root/tests/ui/unsafe-fields/unsafe-fields-parse.rs
blob: 67277731293a7d0980856ad34cf90a1ac717b327 (plain)
1
2
3
4
5
6
7
8
9
10
//@ compile-flags: --crate-type=lib
#![allow(incomplete_features)]
#![feature(unsafe_fields)]

// Parse errors even *with* unsafe_fields, which would make the compiler early-exit otherwise.
enum A {
    TupleLike(unsafe u32), //~ ERROR
}

struct B(unsafe u32); //~ ERROR