-
Notifications
You must be signed in to change notification settings - Fork 12.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix a numerical underflow in tuple wrap suggestion
- Loading branch information
1 parent
29c5a02
commit 43c0c63
Showing
3 changed files
with
26 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
fn main() { | ||
let f = |_: (), f: fn()| f; | ||
let _f = f(main); | ||
//~^ ERROR this function takes 2 arguments but 1 argument was supplied | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
error[E0057]: this function takes 2 arguments but 1 argument was supplied | ||
--> $DIR/issue-99482.rs:3:14 | ||
| | ||
LL | let _f = f(main); | ||
| ^ ---- an argument of type `()` is missing | ||
| | ||
note: closure defined here | ||
--> $DIR/issue-99482.rs:2:13 | ||
| | ||
LL | let f = |_: (), f: fn()| f; | ||
| ^^^^^^^^^^^^^^^^ | ||
help: provide the argument | ||
| | ||
LL | let _f = f((), main); | ||
| ~~~~~~~~~~~ | ||
|
||
error: aborting due to previous error | ||
|
||
For more information about this error, try `rustc --explain E0057`. |