Add bidirectional where clauses on RPITIT synthesized GATs

This commit is contained in:
Santiago Pastorino 2023-06-21 19:09:18 -03:00
parent d70deac161
commit 4925b57782
No known key found for this signature in database
GPG key ID: 8131A24E0C79EFAF
6 changed files with 92 additions and 36 deletions

View file

@ -2664,6 +2664,10 @@ pub struct OpaqueTy<'hir> {
pub generics: &'hir Generics<'hir>,
pub bounds: GenericBounds<'hir>,
pub origin: OpaqueTyOrigin,
// Opaques have duplicated lifetimes, this mapping connects the original lifetime with the copy
// so we can later generate bidirectional outlives predicates to enforce that these lifetimes
// stay in sync.
pub lifetime_mapping: &'hir [(Lifetime, LocalDefId)],
pub in_trait: bool,
}