|
1 |
| -error: cannot introduce explicit parameters for a closure |
| 1 | +error: expected one of `move`, `static`, `|`, or `||`, found `::` |
| 2 | + --> $DIR/recover-quantified-closure.rs:10:14 |
| 3 | + | |
| 4 | +LL | for <Foo>::Bar in x {} |
| 5 | + | ^^ expected one of `move`, `static`, `|`, or `||` |
| 6 | + |
| 7 | +error[E0261]: use of undeclared lifetime name `'a` |
| 8 | + --> $DIR/recover-quantified-closure.rs:2:18 |
| 9 | + | |
| 10 | +LL | fn main() { |
| 11 | + | - help: consider introducing lifetime `'a` here: `<'a>` |
| 12 | +LL | for<'a> |x: &'a u8| *x + 1; |
| 13 | + | ^^ undeclared lifetime |
| 14 | + |
| 15 | +error[E0658]: `for<...>` binders for closures are experimental |
2 | 16 | --> $DIR/recover-quantified-closure.rs:2:5
|
3 | 17 | |
|
4 | 18 | LL | for<'a> |x: &'a u8| *x + 1;
|
5 |
| - | ^^^^^^^ ------------------ the parameters are attached to this closure |
6 |
| - | | |
7 |
| - | help: remove the parameters |
| 19 | + | ^^^^^^^ |
| 20 | + | |
| 21 | + = note: see issue #97362 <https://github.com/rust-lang/rust/issues/97362> for more information |
| 22 | + = help: add `#![feature(closure_lifetime_binder)]` to the crate attributes to enable |
| 23 | + = help: consider removing `for<...>` |
8 | 24 |
|
9 |
| -error: expected one of `move`, `static`, `|`, or `||`, found `::` |
10 |
| - --> $DIR/recover-quantified-closure.rs:8:14 |
| 25 | +error[E0658]: `for<...>` binders for closures are experimental |
| 26 | + --> $DIR/recover-quantified-closure.rs:10:5 |
11 | 27 | |
|
12 | 28 | LL | for <Foo>::Bar in x {}
|
13 |
| - | ^^ expected one of `move`, `static`, `|`, or `||` |
| 29 | + | ^^^^^^^^^ |
| 30 | + | |
| 31 | + = note: see issue #97362 <https://github.com/rust-lang/rust/issues/97362> for more information |
| 32 | + = help: add `#![feature(closure_lifetime_binder)]` to the crate attributes to enable |
| 33 | + = help: consider removing `for<...>` |
| 34 | + |
| 35 | +error: `for<...>` binders for closures are not yet supported |
| 36 | + --> $DIR/recover-quantified-closure.rs:2:5 |
| 37 | + | |
| 38 | +LL | for<'a> |x: &'a u8| *x + 1; |
| 39 | + | ^^^^^^^ |
| 40 | + | |
| 41 | + = help: consider removing `for<...>` |
14 | 42 |
|
15 |
| -error: aborting due to 2 previous errors |
| 43 | +error: aborting due to 5 previous errors |
16 | 44 |
|
| 45 | +Some errors have detailed explanations: E0261, E0658. |
| 46 | +For more information about an error, try `rustc --explain E0261`. |
0 commit comments