@@ -1150,8 +1150,8 @@ impl<'tcx> ToPolyTraitRef<'tcx> for PolyTraitPredicate<'tcx> {
11501150 }
11511151}
11521152
1153- pub trait ToPredicate < ' tcx , Predicate > {
1154- fn to_predicate ( self , tcx : TyCtxt < ' tcx > ) -> Predicate ;
1153+ pub trait ToPredicate < ' tcx , P = Predicate < ' tcx > > {
1154+ fn to_predicate ( self , tcx : TyCtxt < ' tcx > ) -> P ;
11551155}
11561156
11571157impl < ' tcx , T > ToPredicate < ' tcx , T > for T {
@@ -1160,21 +1160,21 @@ impl<'tcx, T> ToPredicate<'tcx, T> for T {
11601160 }
11611161}
11621162
1163- impl < ' tcx > ToPredicate < ' tcx , Predicate < ' tcx > > for Binder < ' tcx , PredicateKind < ' tcx > > {
1163+ impl < ' tcx > ToPredicate < ' tcx > for Binder < ' tcx , PredicateKind < ' tcx > > {
11641164 #[ inline( always) ]
11651165 fn to_predicate ( self , tcx : TyCtxt < ' tcx > ) -> Predicate < ' tcx > {
11661166 tcx. mk_predicate ( self )
11671167 }
11681168}
11691169
1170- impl < ' tcx > ToPredicate < ' tcx , Predicate < ' tcx > > for Clause < ' tcx > {
1170+ impl < ' tcx > ToPredicate < ' tcx > for Clause < ' tcx > {
11711171 #[ inline( always) ]
11721172 fn to_predicate ( self , tcx : TyCtxt < ' tcx > ) -> Predicate < ' tcx > {
11731173 tcx. mk_predicate ( ty:: Binder :: dummy ( ty:: PredicateKind :: Clause ( self ) ) )
11741174 }
11751175}
11761176
1177- impl < ' tcx > ToPredicate < ' tcx , Predicate < ' tcx > > for Binder < ' tcx , TraitRef < ' tcx > > {
1177+ impl < ' tcx > ToPredicate < ' tcx > for Binder < ' tcx , TraitRef < ' tcx > > {
11781178 #[ inline( always) ]
11791179 fn to_predicate ( self , tcx : TyCtxt < ' tcx > ) -> Predicate < ' tcx > {
11801180 let pred: PolyTraitPredicate < ' tcx > = self . to_predicate ( tcx) ;
@@ -1193,25 +1193,25 @@ impl<'tcx> ToPredicate<'tcx, PolyTraitPredicate<'tcx>> for Binder<'tcx, TraitRef
11931193 }
11941194}
11951195
1196- impl < ' tcx > ToPredicate < ' tcx , Predicate < ' tcx > > for PolyTraitPredicate < ' tcx > {
1196+ impl < ' tcx > ToPredicate < ' tcx > for PolyTraitPredicate < ' tcx > {
11971197 fn to_predicate ( self , tcx : TyCtxt < ' tcx > ) -> Predicate < ' tcx > {
11981198 self . map_bound ( |p| PredicateKind :: Clause ( Clause :: Trait ( p) ) ) . to_predicate ( tcx)
11991199 }
12001200}
12011201
1202- impl < ' tcx > ToPredicate < ' tcx , Predicate < ' tcx > > for PolyRegionOutlivesPredicate < ' tcx > {
1202+ impl < ' tcx > ToPredicate < ' tcx > for PolyRegionOutlivesPredicate < ' tcx > {
12031203 fn to_predicate ( self , tcx : TyCtxt < ' tcx > ) -> Predicate < ' tcx > {
12041204 self . map_bound ( |p| PredicateKind :: Clause ( Clause :: RegionOutlives ( p) ) ) . to_predicate ( tcx)
12051205 }
12061206}
12071207
1208- impl < ' tcx > ToPredicate < ' tcx , Predicate < ' tcx > > for PolyTypeOutlivesPredicate < ' tcx > {
1208+ impl < ' tcx > ToPredicate < ' tcx > for PolyTypeOutlivesPredicate < ' tcx > {
12091209 fn to_predicate ( self , tcx : TyCtxt < ' tcx > ) -> Predicate < ' tcx > {
12101210 self . map_bound ( |p| PredicateKind :: Clause ( Clause :: TypeOutlives ( p) ) ) . to_predicate ( tcx)
12111211 }
12121212}
12131213
1214- impl < ' tcx > ToPredicate < ' tcx , Predicate < ' tcx > > for PolyProjectionPredicate < ' tcx > {
1214+ impl < ' tcx > ToPredicate < ' tcx > for PolyProjectionPredicate < ' tcx > {
12151215 fn to_predicate ( self , tcx : TyCtxt < ' tcx > ) -> Predicate < ' tcx > {
12161216 self . map_bound ( |p| PredicateKind :: Clause ( Clause :: Projection ( p) ) ) . to_predicate ( tcx)
12171217 }
0 commit comments