]> git.proxmox.com Git - rustc.git/blob - src/test/ui/parser/mut-patterns.stderr
Merge branch 'debian/sid' into debian/experimental
[rustc.git] / src / test / ui / parser / mut-patterns.stderr
1 error: `mut` must be followed by a named binding
2 --> $DIR/mut-patterns.rs:9:9
3 |
4 LL | let mut _ = 0;
5 | ^^^^^ help: remove the `mut` prefix: `_`
6 |
7 = note: `mut` may be followed by `variable` and `variable @ pattern`
8
9 error: `mut` must be followed by a named binding
10 --> $DIR/mut-patterns.rs:10:9
11 |
12 LL | let mut (_, _) = (0, 0);
13 | ^^^^^^^^^^ help: remove the `mut` prefix: `(_, _)`
14 |
15 = note: `mut` may be followed by `variable` and `variable @ pattern`
16
17 error: `mut` on a binding may not be repeated
18 --> $DIR/mut-patterns.rs:12:13
19 |
20 LL | let mut mut x = 0;
21 | ^^^ help: remove the additional `mut`s
22
23 error: `mut` must be attached to each individual binding
24 --> $DIR/mut-patterns.rs:17:9
25 |
26 LL | let mut Foo { x: x } = Foo { x: 3 };
27 | ^^^^^^^^^^^^^^^^ help: add `mut` to each binding: `Foo { x: mut x }`
28 |
29 = note: `mut` may be followed by `variable` and `variable @ pattern`
30
31 error: `mut` must be attached to each individual binding
32 --> $DIR/mut-patterns.rs:21:9
33 |
34 LL | let mut Foo { x } = Foo { x: 3 };
35 | ^^^^^^^^^^^^^ help: add `mut` to each binding: `Foo { mut x }`
36 |
37 = note: `mut` may be followed by `variable` and `variable @ pattern`
38
39 error: `mut` on a binding may not be repeated
40 --> $DIR/mut-patterns.rs:26:13
41 |
42 LL | let mut mut yield(become, await) = r#yield(0, 0);
43 | ^^^ help: remove the additional `mut`s
44
45 error: expected identifier, found reserved keyword `yield`
46 --> $DIR/mut-patterns.rs:26:17
47 |
48 LL | let mut mut yield(become, await) = r#yield(0, 0);
49 | ^^^^^ expected identifier, found reserved keyword
50 help: you can escape reserved keywords to use them as identifiers
51 |
52 LL | let mut mut r#yield(become, await) = r#yield(0, 0);
53 | ^^^^^^^
54
55 error: expected identifier, found reserved keyword `become`
56 --> $DIR/mut-patterns.rs:26:23
57 |
58 LL | let mut mut yield(become, await) = r#yield(0, 0);
59 | ^^^^^^ expected identifier, found reserved keyword
60 help: you can escape reserved keywords to use them as identifiers
61 |
62 LL | let mut mut yield(r#become, await) = r#yield(0, 0);
63 | ^^^^^^^^
64
65 error: expected identifier, found keyword `await`
66 --> $DIR/mut-patterns.rs:26:31
67 |
68 LL | let mut mut yield(become, await) = r#yield(0, 0);
69 | ^^^^^ expected identifier, found keyword
70 help: you can escape reserved keywords to use them as identifiers
71 |
72 LL | let mut mut yield(become, r#await) = r#yield(0, 0);
73 | ^^^^^^^
74
75 error: `mut` must be attached to each individual binding
76 --> $DIR/mut-patterns.rs:26:9
77 |
78 LL | let mut mut yield(become, await) = r#yield(0, 0);
79 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add `mut` to each binding: `r#yield(mut r#become, mut r#await)`
80 |
81 = note: `mut` may be followed by `variable` and `variable @ pattern`
82
83 error: `mut` must be attached to each individual binding
84 --> $DIR/mut-patterns.rs:35:9
85 |
86 LL | let mut W(mut a, W(b, W(ref c, W(d, B { box f }))))
87 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: add `mut` to each binding: `W(mut a, W(mut b, W(ref c, W(mut d, B { box mut f }))))`
88 |
89 = note: `mut` may be followed by `variable` and `variable @ pattern`
90
91 error: expected identifier, found `x`
92 --> $DIR/mut-patterns.rs:42:21
93 |
94 LL | let mut $p = 0;
95 | ^^ expected identifier
96 ...
97 LL | foo!(x);
98 | -------- in this macro invocation
99
100 error: aborting due to 12 previous errors
101