1
Fork 0

Auto merge of #97024 - lcnr:simplify_type-sus, r=<try>

`simplify_type` improvements and cursed docs

the existing `TreatParams` enum pretty much mixes everything up. Not sure why this looked right to me in #94057

This also includes two changes which impact perf:
- `ty::Projection` with inference vars shouldn't be treated as a rigid type, even if fully normalized
- `ty::Placeholder` only unifies with itself, so actually return `Some` for them

r? `@nikomatsakis`
This commit is contained in:
bors 2022-05-19 13:08:51 +00:00
commit c067287049
9 changed files with 63 additions and 86 deletions

View file

@ -1804,7 +1804,7 @@ impl<'a, 'tcx> EncodeContext<'a, 'tcx> {
let simplified_self_ty = fast_reject::simplify_type(
self.tcx,
trait_ref.self_ty(),
TreatParams::AsPlaceholders,
TreatParams::AsInfer,
);
fx_hash_map