Resolve projections during internal mutability analysis
This commit is contained in:
parent
d79f86255d
commit
58d4834097
4 changed files with 96 additions and 0 deletions
|
|
@ -1227,6 +1227,10 @@ impl<'tcx> InteriorMut<'tcx> {
|
|||
.find_map(|f| self.interior_mut_ty_chain(cx, f.ty(cx.tcx, args)))
|
||||
}
|
||||
},
|
||||
ty::Alias(ty::Projection, _) => match cx.tcx.try_normalize_erasing_regions(cx.typing_env(), ty) {
|
||||
Ok(normalized_ty) if ty != normalized_ty => self.interior_mut_ty_chain(cx, normalized_ty),
|
||||
_ => None,
|
||||
},
|
||||
_ => None,
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue