File tree 3 files changed +7
-1
lines changed
3 files changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -2947,6 +2947,7 @@ impl<'a> Parser<'a> {
2947
2947
{ // Foo<Bar<Baz<Qux, ()>>>
2948
2948
err. help (
2949
2949
"use `::<...>` instead of `<...>` if you meant to specify type arguments" ) ;
2950
+ err. help ( "or use `(...)` if you meant to specify fn arguments" ) ;
2950
2951
}
2951
2952
err. emit ( ) ;
2952
2953
}
Original file line number Diff line number Diff line change @@ -21,5 +21,6 @@ fn main() {
21
21
22
22
f<X >( ) ;
23
23
//~^ ERROR: chained comparison operators require parentheses
24
- //~^^ HELP: use `::<...>` instead of `<...>`
24
+ //~| HELP: use `::<...>` instead of `<...>`
25
+ //~| HELP: or use `(...)`
25
26
}
Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ error: chained comparison operators require parentheses
5
5
| ^^^^^^^^
6
6
|
7
7
= help: use `::<...>` instead of `<...>` if you meant to specify type arguments
8
+ = help: or use `(...)` if you meant to specify fn arguments
8
9
9
10
error: chained comparison operators require parentheses
10
11
--> $DIR/issue-40396.rs:16:25
@@ -13,6 +14,7 @@ error: chained comparison operators require parentheses
13
14
| ^^^^^^^
14
15
|
15
16
= help: use `::<...>` instead of `<...>` if you meant to specify type arguments
17
+ = help: or use `(...)` if you meant to specify fn arguments
16
18
17
19
error: chained comparison operators require parentheses
18
20
--> $DIR/issue-40396.rs:20:37
@@ -21,6 +23,7 @@ error: chained comparison operators require parentheses
21
23
| ^^^^^^^^
22
24
|
23
25
= help: use `::<...>` instead of `<...>` if you meant to specify type arguments
26
+ = help: or use `(...)` if you meant to specify fn arguments
24
27
25
28
error: chained comparison operators require parentheses
26
29
--> $DIR/issue-40396.rs:20:41
@@ -29,6 +32,7 @@ error: chained comparison operators require parentheses
29
32
| ^^^^^^
30
33
|
31
34
= help: use `::<...>` instead of `<...>` if you meant to specify type arguments
35
+ = help: or use `(...)` if you meant to specify fn arguments
32
36
33
37
error: aborting due to 4 previous errors
34
38
You can’t perform that action at this time.
0 commit comments