-
Notifications
You must be signed in to change notification settings - Fork 13.7k
Resolver: Batched Import Resolution #145108
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
base: master
Are you sure you want to change the base?
Resolver: Batched Import Resolution #145108
Conversation
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Code looks a little better now and should be more correct than the previous commits, but I have yet to find a way to resolve the current test failures. |
This comment has been minimized.
This comment has been minimized.
Okey, I did fix |
a3f8ae2
to
4a2a0dc
Compare
This comment has been minimized.
This comment has been minimized.
Could you update the tests to make CI green, so I can see the difference? |
tests/ui/imports/ambiguous-9.rs
Outdated
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 one is definitely wrong.
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 one is wrong as well.
Moving |
I'll create a pr for it. |
This comment has been minimized.
This comment has been minimized.
// This function is only called for glob imports. | ||
let ImportKind::Glob { id, .. } = import.kind else { unreachable!() }; | ||
let ImportKind::Glob { .. } = import.kind else { unreachable!() }; |
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 line does nothing now.
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.
But shouldn't there be a check anyway?
Besides #145108 (comment) potentially, I don't see why this could cause errors in libcore just by reading the diff. |
a8be4d2
to
1c3103a
Compare
This PR was rebased onto a different master commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
I have no idea why these errors are still thrown. It has to do with the structure of the modules where we import // Separate module to reexport the macro `Debug` from prelude without the trait `Debug`.
pub(crate) mod macros {
/// Derive macro generating an impl of the trait `Debug`.
pub macro Debug($item:item) {
/* compiler built-in */
}
}
pub use macros::Debug; Same with `simd. mod core_simd;
#[unstable(feature = "portable_simd", issue = "86656")]
pub mod simd {
pub use crate::core_simd::simd::*;
} But it's pretty hard to debug this. Maybe you know a way? Or have a separate set of eyes look at this? And then there are Edit, is it possible this comment above
|
This comment has been minimized.
This comment has been minimized.
The job Click to see the possible cause of the failure (guessed by this bot)
|
The libcore errors appear when |
Maybe the commit loop will have to be split into two loops, the first one just setting |
Transforms the current algorithm for resolving imports to a batched algorithm. Every import in the
indeterminate_imports
set is resolved in isolation. This is the only real difference from the current algorithm.r? petrochenkov