-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Point at argument instead of call for their obligations #88719
Merged
Merged
Commits on Sep 16, 2021
-
Point at argument instead of call for their obligations
When an obligation is introduced by a specific `fn` argument, point at the argument instead of the `fn` call if the obligation fails to be fulfilled.
Configuration menu - View commit details
-
Copy full SHA for 284a8a9 - Browse repository at this point
Copy the full SHA 284a8a9View commit details -
Refactor
FulfillmentError
to track less dataMove the information about pointing at the call argument expression in an unmet obligation span from the `FulfillmentError` to a new `ObligationCauseCode`.
Configuration menu - View commit details
-
Copy full SHA for 8a3f712 - Browse repository at this point
Copy the full SHA 8a3f712View commit details -
Configuration menu - View commit details
-
Copy full SHA for 569a842 - Browse repository at this point
Copy the full SHA 569a842View commit details -
Account for blocks in arguments
When giving an error about an obligation introduced by a function call that an argument doesn't fulfill, and that argument is a block, add a span_label pointing at the innermost tail expression.
Configuration menu - View commit details
-
Copy full SHA for 22318f1 - Browse repository at this point
Copy the full SHA 22318f1View commit details -
Configuration menu - View commit details
-
Copy full SHA for f7c4a50 - Browse repository at this point
Copy the full SHA f7c4a50View commit details -
Configuration menu - View commit details
-
Copy full SHA for dbecdd5 - Browse repository at this point
Copy the full SHA dbecdd5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 88a5321 - Browse repository at this point
Copy the full SHA 88a5321View commit details -
Configuration menu - View commit details
-
Copy full SHA for 1d82905 - Browse repository at this point
Copy the full SHA 1d82905View commit details -
Point at argument when evaluating
Path
's boundsWhen evaluating an `ExprKind::Call`, we first have to `check_expr` on it's callee. When this one is a `ExprKind::Path`, we had to evaluate the bounds introduced for its arguments, but by the time we evaluated them we no longer had access to the argument spans. Now we special case this so that we can point at the right place on unsatisfied bounds. This also allows the E0277 deduplication to kick in correctly, so we now emit fewer errors.
Configuration menu - View commit details
-
Copy full SHA for 4951e3a - Browse repository at this point
Copy the full SHA 4951e3aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 0a4540b - Browse repository at this point
Copy the full SHA 0a4540bView commit details
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.