-
Notifications
You must be signed in to change notification settings - Fork 13k
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
Prefer lower vtable candidates in select in new solver #124724
Conversation
Some changes occurred to the core trait solver cc @rust-lang/initiative-trait-system-refactor |
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.
r=me after nits
c6922aa
to
024a9b8
Compare
@@ -85,8 +91,7 @@ fn candidate_should_be_dropped_in_favor_of<'tcx>( | |||
victim: &inspect::InspectCandidate<'_, 'tcx>, | |||
other: &inspect::InspectCandidate<'_, 'tcx>, | |||
) -> bool { | |||
// Don't winnow until `Certainty::Yes` -- we don't need to winnow until | |||
// codegen, technically. | |||
// codegen, technically, and all goals should hold in codegen. |
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.
fff
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 comment doesn't make sense to me 🤔 candidates can overflow in codegen, so there can always be uncertainty
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 guess I mean on the good path. Unless you think we should winnow ambig candidates, or something.
024a9b8
to
a4ee20e
Compare
@bors r+ rollup |
…iaskrgr Rollup of 4 pull requests Successful merges: - rust-lang#124520 (Document that `create_dir_all` calls `mkdir`/`CreateDirW` multiple times) - rust-lang#124724 (Prefer lower vtable candidates in select in new solver) - rust-lang#124771 (Don't consider candidates with no failing where clauses when refining obligation causes in new solver) - rust-lang#124808 (Use `super_fold` in `RegionsToStatic` visitor) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#124724 - compiler-errors:prefer-lower, r=lcnr Prefer lower vtable candidates in select in new solver Also, adjust the select visitor to only winnow when the *parent* goal is `Certainty::Yes`. This means that we won't winnow in cases when we have any ambiguous inference guidance from two candidates. r? lcnr
Also, adjust the select visitor to only winnow when the parent goal is
Certainty::Yes
. This means that we won't winnow in cases when we have any ambiguous inference guidance from two candidates.r? lcnr