@@ -5,16 +5,11 @@ LL | if let S { x: _x, y: 2 } = S { x: 1, y: 2 } { println!("Ok"); }
5
5
| ^ expecting a type here because of type ascription
6
6
|
7
7
= note: type ascription is a nightly-only feature that lets you annotate an expression with a type: `<expr>: <type>`
8
- note: this expression is annotated with type ascription...
8
+ note: this expression expects an ascribed type after the colon
9
9
--> $DIR/E0423.rs:12:36
10
10
|
11
11
LL | if let S { x: _x, y: 2 } = S { x: 1, y: 2 } { println!("Ok"); }
12
12
| ^
13
- note: ...due to this, which is why a type is expected after
14
- --> $DIR/E0423.rs:12:37
15
- |
16
- LL | if let S { x: _x, y: 2 } = S { x: 1, y: 2 } { println!("Ok"); }
17
- | ^
18
13
= help: this might be indicative of a syntax error elsewhere
19
14
20
15
error: expected expression, found `==`
@@ -30,16 +25,11 @@ LL | for _ in std::ops::Range { start: 0, end: 10 } {}
30
25
| ^ expecting a type here because of type ascription
31
26
|
32
27
= note: type ascription is a nightly-only feature that lets you annotate an expression with a type: `<expr>: <type>`
33
- note: this expression is annotated with type ascription...
28
+ note: this expression expects an ascribed type after the colon
34
29
--> $DIR/E0423.rs:21:32
35
30
|
36
31
LL | for _ in std::ops::Range { start: 0, end: 10 } {}
37
32
| ^^^^^
38
- note: ...due to this, which is why a type is expected after
39
- --> $DIR/E0423.rs:21:37
40
- |
41
- LL | for _ in std::ops::Range { start: 0, end: 10 } {}
42
- | ^
43
33
= help: this might be indicative of a syntax error elsewhere
44
34
45
35
error[E0423]: expected function, found struct `Foo`
0 commit comments