@@ -126,12 +126,12 @@ pub(crate) fn type_check<'gcx, 'tcx>(
126126) -> MirTypeckResults < ' tcx > {
127127 let implicit_region_bound = infcx. tcx . mk_region ( ty:: ReVar ( universal_regions. fr_fn_body ) ) ;
128128 let mut constraints = MirTypeckRegionConstraints {
129+ placeholder_indices : PlaceholderIndices :: default ( ) ,
129130 liveness_constraints : LivenessValues :: new ( elements) ,
130131 outlives_constraints : ConstraintSet :: default ( ) ,
131132 closure_bounds_mapping : Default :: default ( ) ,
132133 type_tests : Vec :: default ( ) ,
133134 } ;
134- let mut placeholder_indices = PlaceholderIndices :: default ( ) ;
135135
136136 let CreateResult {
137137 universal_region_relations,
@@ -151,7 +151,6 @@ pub(crate) fn type_check<'gcx, 'tcx>(
151151 borrow_set,
152152 all_facts,
153153 constraints : & mut constraints,
154- placeholder_indices : & mut placeholder_indices,
155154 } ;
156155
157156 type_check_internal (
@@ -175,7 +174,6 @@ pub(crate) fn type_check<'gcx, 'tcx>(
175174
176175 MirTypeckResults {
177176 constraints,
178- placeholder_indices,
179177 universal_region_relations,
180178 }
181179}
@@ -730,18 +728,18 @@ struct BorrowCheckContext<'a, 'tcx: 'a> {
730728 all_facts : & ' a mut Option < AllFacts > ,
731729 borrow_set : & ' a BorrowSet < ' tcx > ,
732730 constraints : & ' a mut MirTypeckRegionConstraints < ' tcx > ,
733- placeholder_indices : & ' a mut PlaceholderIndices ,
734731}
735732
736733crate struct MirTypeckResults < ' tcx > {
737734 crate constraints : MirTypeckRegionConstraints < ' tcx > ,
738- crate placeholder_indices : PlaceholderIndices ,
739735 crate universal_region_relations : Rc < UniversalRegionRelations < ' tcx > > ,
740736}
741737
742738/// A collection of region constraints that must be satisfied for the
743739/// program to be considered well-typed.
744740crate struct MirTypeckRegionConstraints < ' tcx > {
741+ crate placeholder_indices : PlaceholderIndices ,
742+
745743 /// In general, the type-checker is not responsible for enforcing
746744 /// liveness constraints; this job falls to the region inferencer,
747745 /// which performs a liveness analysis. However, in some limited
0 commit comments