rust/tests/ui/parser/pat-lt-bracket-7.rs

10 lines
235 B
Rust
Raw Normal View History

2015-04-03 05:56:27 +03:00
fn main() {
2019-07-24 02:30:37 +02:00
struct Thing(u8, [u8; 0]);
let foo = core::iter::empty();
for Thing(x[]) in foo {}
//~^ ERROR: expected one of `)`, `,`, `@`, or `|`, found `[`
2015-04-03 05:56:27 +03:00
}
2019-07-24 02:30:37 +02:00
const RECOVERY_WITNESS: () = 0; //~ ERROR mismatched types