-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Provide the full span of method calls to check_argument_types
#45123
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
r? @eddyb (rust_highfive has picked a reviewer for you, use r? to override) |
r? @oli-obk |
You need to fix method-call-err-msg.rs , too. This will include the args on other errors, too. can you add examples of those errors as ui tests, so we know how they look now? Maybe just move method-call-err-msg.rs to ui tests |
5736fca
to
53a10a4
Compare
I moved it to ui tests. I don't know if the new output is really great though, maybe it should just point at the parens |
26 | | //~^ NOTE expected 0 parameters | ||
27 | | //~^ ERROR this function takes 1 parameter but 0 parameters were supplied | ||
28 | | //~^ NOTE expected 1 parameter | ||
29 | | .one() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a definite regression. It used to produce
error[E0061]: this function takes 1 parameter but 0 parameters were supplied
--> src/main.rs:15:7
|
5 | fn one(self, _: isize) -> Foo { self }
| -------------------------------------- defined here
...
15 | .one() //~ ERROR this function takes 1 parameter but 0 parameters were supplied
| ^^^ expected 1 parameter
And we really want to keep the old report
53a10a4
to
bb4d1ca
Compare
updated to keep the old error message |
Lgtm now. @eddyb can you r+? |
@bors r=oli-obk |
📌 Commit bb4d1ca has been approved by |
Provide the full span of method calls to `check_argument_types` ... so that it includes the span of the passed arguments, not just the name of the called method. Fixes #44760.
☀️ Test successful - status-appveyor, status-travis |
... so that it includes the span of the passed arguments, not just the name of the called method.
Fixes #44760.