|
| 1 | +error: expected identifier, found reserved identifier `_` |
| 2 | + --> $DIR/issue-89066.rs:12:17 |
| 3 | + | |
| 4 | +LL | struct BadInfer<_>; |
| 5 | + | ^ expected identifier, found reserved identifier |
| 6 | + |
| 7 | +error: expected identifier, found reserved identifier `_` |
| 8 | + --> $DIR/issue-89066.rs:18:17 |
| 9 | + | |
| 10 | +LL | fn bad_infer_fn<_>() {} |
| 11 | + | ^ expected identifier, found reserved identifier |
| 12 | + |
| 13 | +error: in expressions, `_` can only be used on the left-hand side of an assignment |
| 14 | + --> $DIR/issue-89066.rs:26:15 |
| 15 | + | |
| 16 | +LL | let v: [u8; _]; |
| 17 | + | ^ `_` not allowed here |
| 18 | + |
| 19 | +error: in expressions, `_` can only be used on the left-hand side of an assignment |
| 20 | + --> $DIR/issue-89066.rs:28:25 |
| 21 | + | |
| 22 | +LL | let v: [u8; 10] = [0; _]; |
| 23 | + | ^ `_` not allowed here |
| 24 | + |
| 25 | +error[E0392]: parameter `_` is never used |
| 26 | + --> $DIR/issue-89066.rs:12:17 |
| 27 | + | |
| 28 | +LL | struct BadInfer<_>; |
| 29 | + | ^ unused parameter |
| 30 | + | |
| 31 | + = help: consider removing `_`, referring to it in a field, or using a marker such as `PhantomData` |
| 32 | + = help: if you intended `_` to be a const parameter, use `const _: usize` instead |
| 33 | + |
| 34 | +error[E0107]: this struct takes 2 generic arguments but 3 generic arguments were supplied |
| 35 | + --> $DIR/issue-89066.rs:23:10 |
| 36 | + | |
| 37 | +LL | let a: All<_, _, _>; |
| 38 | + | ^^^ - help: remove this generic argument |
| 39 | + | | |
| 40 | + | expected 2 generic arguments |
| 41 | + | |
| 42 | +note: struct defined here, with 2 generic parameters: `T`, `N` |
| 43 | + --> $DIR/issue-89066.rs:8:8 |
| 44 | + | |
| 45 | +LL | struct All<'a, T, const N: usize> { |
| 46 | + | ^^^ - - |
| 47 | + |
| 48 | +error: aborting due to 6 previous errors |
| 49 | + |
| 50 | +Some errors have detailed explanations: E0107, E0392. |
| 51 | +For more information about an error, try `rustc --explain E0107`. |
0 commit comments