77 lines
2.5 KiB
Plaintext
77 lines
2.5 KiB
Plaintext
error: `mut` must be followed by a named binding
|
|
--> $DIR/mut-patterns.rs:9:9
|
|
|
|
|
LL | let mut _ = 0;
|
|
| ^^^^ help: remove the `mut` prefix
|
|
|
|
|
= note: `mut` may be followed by `variable` and `variable @ pattern`
|
|
|
|
error: `mut` must be followed by a named binding
|
|
--> $DIR/mut-patterns.rs:10:9
|
|
|
|
|
LL | let mut (_, _) = (0, 0);
|
|
| ^^^^ help: remove the `mut` prefix
|
|
|
|
|
= note: `mut` may be followed by `variable` and `variable @ pattern`
|
|
|
|
error: `mut` must be attached to each individual binding
|
|
--> $DIR/mut-patterns.rs:12:9
|
|
|
|
|
LL | let mut (x @ y) = 0;
|
|
| ^^^^^^^^^^^ help: add `mut` to each binding: `(mut x @ mut y)`
|
|
|
|
|
= note: `mut` may be followed by `variable` and `variable @ pattern`
|
|
|
|
error: `mut` on a binding may not be repeated
|
|
--> $DIR/mut-patterns.rs:14:13
|
|
|
|
|
LL | let mut mut x = 0;
|
|
| ^^^ help: remove the additional `mut`s
|
|
|
|
error: `mut` must be attached to each individual binding
|
|
--> $DIR/mut-patterns.rs:19:9
|
|
|
|
|
LL | let mut Foo { x: x } = Foo { x: 3 };
|
|
| ^^^^^^^^^^^^^^^^ help: add `mut` to each binding: `Foo { x: mut x }`
|
|
|
|
|
= note: `mut` may be followed by `variable` and `variable @ pattern`
|
|
|
|
error: `mut` must be attached to each individual binding
|
|
--> $DIR/mut-patterns.rs:23:9
|
|
|
|
|
LL | let mut Foo { x } = Foo { x: 3 };
|
|
| ^^^^^^^^^^^^^ help: add `mut` to each binding: `Foo { mut x }`
|
|
|
|
|
= note: `mut` may be followed by `variable` and `variable @ pattern`
|
|
|
|
error: `mut` on a binding may not be repeated
|
|
--> $DIR/mut-patterns.rs:28:13
|
|
|
|
|
LL | let mut mut yield(become, await) = r#yield(0, 0);
|
|
| ^^^ help: remove the additional `mut`s
|
|
|
|
error: expected identifier, found reserved keyword `yield`
|
|
--> $DIR/mut-patterns.rs:28:17
|
|
|
|
|
LL | let mut mut yield(become, await) = r#yield(0, 0);
|
|
| ^^^^^ expected identifier, found reserved keyword
|
|
|
|
|
help: escape `yield` to use it as an identifier
|
|
|
|
|
LL | let mut mut r#yield(become, await) = r#yield(0, 0);
|
|
| ++
|
|
|
|
error: expected identifier, found reserved keyword `become`
|
|
--> $DIR/mut-patterns.rs:28:23
|
|
|
|
|
LL | let mut mut yield(become, await) = r#yield(0, 0);
|
|
| ^^^^^^ expected identifier, found reserved keyword
|
|
|
|
|
help: escape `become` to use it as an identifier
|
|
|
|
|
LL | let mut mut yield(r#become, await) = r#yield(0, 0);
|
|
| ++
|
|
|
|
error: aborting due to 9 previous errors
|
|
|