]> git.lizzy.rs Git - rust.git/blob - src/test/ui/parser/recover-quantified-closure.rs
Merge commit 'e228f0c16ea8c34794a6285bf57aab627c26b147' into libgccjit-codegen
[rust.git] / src / test / ui / parser / recover-quantified-closure.rs
1 fn main() {
2     for<'a> |x: &'a u8| *x + 1;
3     //~^ ERROR cannot introduce explicit parameters for a closure
4 }
5
6 enum Foo { Bar }
7 fn foo(x: impl Iterator<Item = Foo>) {
8     for <Foo>::Bar in x {}
9     //~^ ERROR expected one of `move`, `static`, `|`
10 }