granite-rust/src/test/ui/parser/mut-patterns.stderr

78 lines
2.8 KiB
Text
Raw Normal View History

error: `mut` on a binding may not be repeated
--> $DIR/mut-patterns.rs:9: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:14:9
2018-10-20 23:36:17 +03:00
|
2019-03-09 15:03:44 +03:00
LL | let mut Foo { x: x } = Foo { x: 3 };
| ^^^^^^^^^^^^^^^^ help: add `mut` to each binding: `Foo { x: mut x }`
error: `mut` must be attached to each individual binding
--> $DIR/mut-patterns.rs:18:9
|
LL | let mut Foo { x } = Foo { x: 3 };
| ^^^^^^^^^^^^^ help: add `mut` to each binding: `Foo { mut x }`
error: `mut` on a binding may not be repeated
--> $DIR/mut-patterns.rs:23: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:23:17
|
LL | let mut mut yield(become, await) = r#yield(0, 0);
| ^^^^^ expected identifier, found reserved keyword
help: you can escape reserved keywords to use them as identifiers
|
LL | let mut mut r#yield(become, await) = r#yield(0, 0);
| ^^^^^^^
error: expected identifier, found reserved keyword `become`
--> $DIR/mut-patterns.rs:23:23
|
LL | let mut mut yield(become, await) = r#yield(0, 0);
| ^^^^^^ expected identifier, found reserved keyword
help: you can escape reserved keywords to use them as identifiers
|
LL | let mut mut yield(r#become, await) = r#yield(0, 0);
| ^^^^^^^^
error: expected identifier, found reserved keyword `await`
--> $DIR/mut-patterns.rs:23:31
|
LL | let mut mut yield(become, await) = r#yield(0, 0);
| ^^^^^ expected identifier, found reserved keyword
help: you can escape reserved keywords to use them as identifiers
|
LL | let mut mut yield(become, r#await) = r#yield(0, 0);
| ^^^^^^^
error: `mut` must be attached to each individual binding
--> $DIR/mut-patterns.rs:23:9
|
LL | let mut mut yield(become, await) = r#yield(0, 0);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add `mut` to each binding: `r#yield(mut r#become, mut r#await)`
error: `mut` must be attached to each individual binding
--> $DIR/mut-patterns.rs:32:9
|
LL | let mut W(mut a, W(b, W(ref c, W(d, B { box f }))))
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add `mut` to each binding: `W(mut a, W(mut b, W(ref c, W(mut d, B { box mut f }))))`
2018-10-20 23:36:17 +03:00
error: expected identifier, found `x`
--> $DIR/mut-patterns.rs:39:21
|
LL | let mut $p = 0;
| ^^ expected identifier
...
LL | foo!(x);
| -------- in this macro invocation
error: aborting due to 10 previous errors
2018-10-20 23:36:17 +03:00