File tree Expand file tree Collapse file tree 3 files changed +4
-13
lines changed Expand file tree Collapse file tree 3 files changed +4
-13
lines changed Original file line number Diff line number Diff line change @@ -843,8 +843,9 @@ impl<'tcx> BorrowckInferCtxt<'tcx> {
843843 {
844844 let ( value, _map) = self . tcx . instantiate_bound_regions ( value, |br| {
845845 debug ! ( ?br) ;
846+ let kind = ty:: LateParamRegionKind :: from_bound ( br. var , br. kind ) ;
846847 let liberated_region =
847- ty:: Region :: new_late_param_from_bound ( self . tcx , all_outlive_scope. to_def_id ( ) , br ) ;
848+ ty:: Region :: new_late_param ( self . tcx , all_outlive_scope. to_def_id ( ) , kind ) ;
848849 let region_vid = {
849850 let name = match br. kind . get_name ( ) {
850851 Some ( name) => name,
Original file line number Diff line number Diff line change @@ -270,7 +270,8 @@ impl<'tcx> TyCtxt<'tcx> {
270270 T : TypeFoldable < TyCtxt < ' tcx > > ,
271271 {
272272 self . instantiate_bound_regions_uncached ( value, |br| {
273- ty:: Region :: new_late_param_from_bound ( self , all_outlive_scope, br)
273+ let kind = ty:: LateParamRegionKind :: from_bound ( br. var , br. kind ) ;
274+ ty:: Region :: new_late_param ( self , all_outlive_scope, kind)
274275 } )
275276 }
276277
Original file line number Diff line number Diff line change @@ -76,17 +76,6 @@ impl<'tcx> Region<'tcx> {
7676 tcx. intern_region ( ty:: ReLateParam ( data) )
7777 }
7878
79- #[ inline]
80- pub fn new_late_param_from_bound (
81- tcx : TyCtxt < ' tcx > ,
82- scope : DefId ,
83- bound : BoundRegion ,
84- ) -> Region < ' tcx > {
85- let data =
86- LateParamRegion { scope, kind : LateParamRegionKind :: from_bound ( bound. var , bound. kind ) } ;
87- tcx. intern_region ( ty:: ReLateParam ( data) )
88- }
89-
9079 #[ inline]
9180 pub fn new_var ( tcx : TyCtxt < ' tcx > , v : ty:: RegionVid ) -> Region < ' tcx > {
9281 // Use a pre-interned one when possible.
You can’t perform that action at this time.
0 commit comments