@@ -399,15 +399,14 @@ impl<'tcx> RegionInferenceContext<'tcx> {
399
399
/// takes on must be a value that each of the regions within the
400
400
/// SCC could have as well. This implies that the SCC must have
401
401
/// the minimum, or narrowest, universe.
402
+ #[ instrument( level="debug" , skip( constraint_sccs, definitions) ) ]
402
403
fn compute_scc_universes (
403
404
constraint_sccs : & Sccs < RegionVid , ConstraintSccIndex > ,
404
405
definitions : & IndexSlice < RegionVid , RegionDefinition < ' tcx > > ,
405
406
) -> IndexVec < ConstraintSccIndex , ty:: UniverseIndex > {
406
407
let num_sccs = constraint_sccs. num_sccs ( ) ;
407
408
let mut scc_universes = IndexVec :: from_elem_n ( ty:: UniverseIndex :: MAX , num_sccs) ;
408
409
409
- debug ! ( "compute_scc_universes()" ) ;
410
-
411
410
// For each region R in universe U, ensure that the universe for the SCC
412
411
// that contains R is "no bigger" than U. This effectively sets the universe
413
412
// for each SCC to be the minimum of the regions within.
@@ -416,15 +415,14 @@ impl<'tcx> RegionInferenceContext<'tcx> {
416
415
let scc_universe = & mut scc_universes[ scc] ;
417
416
let scc_min = std:: cmp:: min ( region_definition. universe , * scc_universe) ;
418
417
if scc_min != * scc_universe {
419
- * scc_universe = scc_min;
420
418
debug ! (
421
- "compute_scc_universes: lowered universe of {scc:?} to {scc_min:?} \
419
+ "compute_scc_universes: lowered universe of {scc:?} from {previous_universe:?} to {scc_min:?} \
422
420
because it contains {region_vid:?} in {region_universe:?}",
423
- scc = scc,
424
- scc_min = scc_min,
425
- region_vid = region_vid,
426
421
region_universe = region_definition. universe,
422
+ previous_universe = scc_universe,
427
423
) ;
424
+
425
+ * scc_universe = scc_min;
428
426
}
429
427
}
430
428
0 commit comments