diff options
Diffstat (limited to '')
-rw-r--r-- | src/test/ui/parser/pat-lt-bracket-7.rs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/test/ui/parser/pat-lt-bracket-7.rs b/src/test/ui/parser/pat-lt-bracket-7.rs new file mode 100644 index 000000000..327aef5ad --- /dev/null +++ b/src/test/ui/parser/pat-lt-bracket-7.rs @@ -0,0 +1,9 @@ +fn main() { + struct Thing(u8, [u8; 0]); + let foo = core::iter::empty(); + + for Thing(x[]) in foo {} + //~^ ERROR: expected one of `)`, `,`, `@`, or `|`, found `[` +} + +const RECOVERY_WITNESS: () = 0; //~ ERROR mismatched types |