summaryrefslogtreecommitdiffstats
path: root/tests/ui/parser/recover-labeled-non-block-expr.stderr
blob: d66ce6950904c53855da6218a86649ef286302a7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
error: expected `while`, `for`, `loop` or `{` after a label
  --> $DIR/recover-labeled-non-block-expr.rs:3:21
   |
LL |     let _ = 'label: 1 + 1;
   |                     ^ expected `while`, `for`, `loop` or `{` after a label
   |
help: consider removing the label
   |
LL -     let _ = 'label: 1 + 1;
LL +     let _ = 1 + 1;
   |

error: expected `while`, `for`, `loop` or `{` after a label
  --> $DIR/recover-labeled-non-block-expr.rs:5:13
   |
LL |     'label: match () { () => {}, };
   |             ^^^^^ expected `while`, `for`, `loop` or `{` after a label
   |
help: consider removing the label
   |
LL -     'label: match () { () => {}, };
LL +     match () { () => {}, };
   |

error: expected `while`, `for`, `loop` or `{` after a label
  --> $DIR/recover-labeled-non-block-expr.rs:6:13
   |
LL |     'label: match () { () => break 'label, };
   |             ^^^^^ expected `while`, `for`, `loop` or `{` after a label
   |
help: consider enclosing expression in a block
   |
LL |     'label: { match () { () => break 'label, } };
   |             +                                  +

error: expected `while`, `for`, `loop` or `{` after a label
  --> $DIR/recover-labeled-non-block-expr.rs:8:13
   |
LL |     'label: match () { () => 'lp: loop { break 'lp 0 }, };
   |             ^^^^^ expected `while`, `for`, `loop` or `{` after a label
   |
help: consider enclosing expression in a block
   |
LL |     'label: { match () { () => 'lp: loop { break 'lp 0 }, } };
   |             +                                               +

error: expected `while`, `for`, `loop` or `{` after a label
  --> $DIR/recover-labeled-non-block-expr.rs:11:22
   |
LL |     let _i = 'label: match x {
   |                      ^^^^^ expected `while`, `for`, `loop` or `{` after a label
   |
help: consider enclosing expression in a block
   |
LL ~     let _i = 'label: { match x {
LL |         0 => 42,
 ...
LL |         _ => 1,
LL ~     } };
   |

error: expected `while`, `for`, `loop` or `{` after a label
  --> $DIR/recover-labeled-non-block-expr.rs:25:24
   |
LL |     let _val = 'label: (1, if other == 3 { break 'label (2, 3) } else { other });
   |                        ^ expected `while`, `for`, `loop` or `{` after a label
   |
help: consider enclosing expression in a block
   |
LL |     let _val = 'label: { (1, if other == 3 { break 'label (2, 3) } else { other }) };
   |                        +                                                           +

error: aborting due to 6 previous errors