Track if a where bound comes from a impl Trait desugar#96770
Merged
bors merged 2 commits intorust-lang:masterfrom May 8, 2022
Merged
Track if a where bound comes from a impl Trait desugar#96770bors merged 2 commits intorust-lang:masterfrom
bors merged 2 commits intorust-lang:masterfrom
Conversation
This reverts commit bb01aca. Partial: Keep regression tests
Contributor
|
Some changes occurred in src/tools/clippy. cc @rust-lang/clippy |
cjgillot
reviewed
May 6, 2022
cjgillot
reviewed
May 6, 2022
Contributor
|
r=me after addressing cjgillot's comment |
bfa15d6 to
65e38fa
Compare
With rust-lang#93803 `impl Trait` function arguments get desugared to hidden where bounds. However, Clippy needs to know if a bound was originally a impl Trait or an actual bound. This adds a field to the `WhereBoundPredicate` struct to keep track of this information during HIR lowering.
65e38fa to
dd1ff40
Compare
Member
Author
|
I think I addressed everything. |
Contributor
|
@bors r+ |
Collaborator
|
📌 Commit dd1ff40 has been approved by |
Collaborator
Collaborator
|
☀️ Test successful - checks-actions |
Collaborator
|
Finished benchmarking commit (ed3164b): comparison url. Summary: This benchmark run did not return any relevant results. If you disagree with this performance assessment, please file an issue in rust-lang/rustc-perf. @rustbot label: -perf-regression |
xFrednet
pushed a commit
to xFrednet/rust
that referenced
this pull request
May 21, 2022
…cjgillot Track if a where bound comes from a impl Trait desugar With rust-lang#93803 `impl Trait` function arguments get desugared to hidden where bounds. However, Clippy needs to know if a bound was originally a `impl Trait` or an actual bound. This adds a field to the `WhereBoundPredicate` struct to keep track of this information during AST->HIR lowering. r? `@cjgillot` cc `@estebank` (as the reviewer of rust-lang#93803)
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
With #93803
impl Traitfunction arguments get desugared to hidden where bounds. However, Clippy needs to know if a bound was originally aimpl Traitor an actual bound. This adds a field to theWhereBoundPredicatestruct to keep track of this information during AST->HIR lowering.r? @cjgillot
cc @estebank (as the reviewer of #93803)