1
Fork 0

Auto merge of #89000 - Mark-Simulacrum:no-new-lrc, r=petrochenkov

Reuse existing shared Lrc for MatchImpl parent

This is a small performance win for the hot path, which helps to address this regression: https://github.com/rust-lang/rust/pull/87244#issuecomment-883635813.
This commit is contained in:
bors 2021-09-18 20:13:21 +00:00
commit aa8f2d432b
4 changed files with 4 additions and 4 deletions

View file

@ -349,7 +349,7 @@ pub enum ObligationCauseCode<'tcx> {
WellFormed(Option<WellFormedLoc>),
/// From `match_impl`. The cause for us having to match an impl, and the DefId we are matching against.
MatchImpl(Lrc<ObligationCauseCode<'tcx>>, DefId),
MatchImpl(ObligationCause<'tcx>, DefId),
}
/// The 'location' at which we try to perform HIR-based wf checking.