You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We probably shouldn't be assembling a builtin discriminant candidate for placeholders at all -- that is, we shouldn't fix it by just assembling <!0t as DiscriminantKind>::Discriminant like the Ty::discriminant_ty impl is doing, but instead treat it as Err(NoSolution) to avoid ambiguity.
…ind-ice, r=lcnr
Don't ICE on `DiscriminantKind` projection in new solver
As title says, since we now actually call `Ty::discriminant_kind` on placeholder types 😃
Also drive-by simplify `Pointee::Metadata` projection logic, and fix the UI test because the `<T as Pointee>::Metadata` tests weren't actually exercising the new projection logic, since we still eagerly normalize (which hits `project.rs` in the old solver) in HIR typeck.
r? `@lcnr` tho feel free to re-roll, this pr is very low-priority and not super specific to the new trait solver.
Fixescompiler-errors/next-solver-hir-issues#14
ICEs with:
We probably shouldn't be assembling a builtin discriminant candidate for placeholders at all -- that is, we shouldn't fix it by just assembling
<!0t as DiscriminantKind>::Discriminant
like theTy::discriminant_ty
impl is doing, but instead treat it asErr(NoSolution)
to avoid ambiguity.https://github.com/rust-lang/rust/blob/f98598c6cd34947efa9e3977338e9bce62d1997c/compiler/rustc_middle/src/ty/sty.rs#L2223
The text was updated successfully, but these errors were encountered: