-
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
Add def path data variant #104648
Add def path data variant #104648
Conversation
@bors try @rust-timer queue |
Awaiting bors try build completion. @rustbot label: +S-waiting-on-perf |
🔒 Merge conflict This pull request and the master branch diverged in a way that cannot be automatically merged. Please rebase on top of the latest master branch, and let the reviewer approve again. How do I rebase?Assuming
You may also read Git Rebasing to Resolve Conflicts by Drew Blessing for a short tutorial. Please avoid the "Resolve conflicts" button on GitHub. It uses Sometimes step 4 will complete without asking for resolution. This is usually due to difference between how Error message
|
e5161b6
to
4c65464
Compare
@bors try @rust-timer queue |
Awaiting bors try build completion. @rustbot label: +S-waiting-on-perf |
⌛ Trying commit 4c65464ed1c5a2bfb507ac05929ba0aecb34102b with merge e8579d4778471621b7779a36e65222948cbbaa63... |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
💔 Test failed - checks-actions |
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.
I'm not sure what the motivation is. Could you elaborate on what this helps with? Why isn't a DefKind
variant not enough?
/// An `impl Trait` type node inside a `trait` or inside an `impl` of a `trait`. | ||
/// On a `trait` the value is `(trait_fn_def_id, None)`. | ||
/// On an `impl` the value is `(impl_fn_def_id, Some(trait_rpit_def_id))`. | ||
ImplTraitInTrait(DefId, Option<DefId>), |
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 may cause issues with incremental compilation. DefPathData
is hashed using Hash
and not StableHasher
. This means that we may change the DefPathHash
when DefIndices
are re-numbered, which is what DefPathHash
is supposed to avoid.
&& let DefPathData::ImplTraitInTrait(fn_def_id, of_trait) = | ||
def_path_data.data | ||
{ | ||
Some((fn_def_id, of_trait)) |
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.
Can this be implemented by walking self.parent
until we find a ValueNs
? As for of_trait
I haven't seen it used anywhere, could it be computed from fn_def_id
?
4c65464
to
41ef055
Compare
@bors try @rust-timer queue |
Awaiting bors try build completion. @rustbot label: +S-waiting-on-perf |
⌛ Trying commit 41ef0554d171a62e0bf13d4f8156109f4f755de9 with merge ce79ba7e68d9b7fa6b693bc310d989b1099eb019... |
This comment has been minimized.
This comment has been minimized.
41ef055
to
7d53d47
Compare
☔ The latest upstream changes (presumably #103491) made this pull request unmergeable. Please resolve the merge conflicts. |
We don't need to use this hack anymore as #104940 was r+ed. |
This one should be merged after #104615
r? @compiler-errors