@@ -492,35 +492,35 @@ impl<'tcx> RegionInferenceContext<'tcx> {
492
492
/// This bit of logic also handles invalid universe relations
493
493
/// for higher-kinded types.
494
494
///
495
- // We Walk each SCC `A` and `B` such that `A: B`
496
- // and ensure that universe(A) can see universe(B).
497
- //
498
- // This serves to enforce the 'empty/placeholder' hierarchy
499
- // (described in more detail on `RegionKind`):
500
- //
501
- // ```
502
- // static -----+
503
- // | |
504
- // empty(U0) placeholder(U1)
505
- // | /
506
- // empty(U1)
507
- // ```
508
- //
509
- // In particular, imagine we have variables R0 in U0 and R1
510
- // created in U1, and constraints like this;
511
- //
512
- // ```
513
- // R1: !1 // R1 outlives the placeholder in U1
514
- // R1: R0 // R1 outlives R0
515
- // ```
516
- //
517
- // Here, we wish for R1 to be `'static`, because it
518
- // cannot outlive `placeholder(U1)` and `empty(U0)` any other way.
519
- //
520
- // Thanks to this loop, what happens is that the `R1: R0`
521
- // constraint has lowered the universe of `R1` to `U0`, which in turn
522
- // means that the `R1: !1` constraint here will cause
523
- // `R1` to become `'static`.
495
+ /// We Walk each SCC `A` and `B` such that `A: B`
496
+ /// and ensure that universe(A) can see universe(B).
497
+ ///
498
+ /// This serves to enforce the 'empty/placeholder' hierarchy
499
+ /// (described in more detail on `RegionKind`):
500
+ ///
501
+ /// ```ignore (illustrative)
502
+ /// static -----+
503
+ /// | |
504
+ /// empty(U0) placeholder(U1)
505
+ /// | /
506
+ /// empty(U1)
507
+ /// ```
508
+ ///
509
+ /// In particular, imagine we have variables R0 in U0 and R1
510
+ /// created in U1, and constraints like this;
511
+ ///
512
+ /// ```ignore (illustrative)
513
+ /// R1: !1 // R1 outlives the placeholder in U1
514
+ /// R1: R0 // R1 outlives R0
515
+ /// ```
516
+ ///
517
+ /// Here, we wish for R1 to be `'static`, because it
518
+ /// cannot outlive `placeholder(U1)` and `empty(U0)` any other way.
519
+ ///
520
+ /// Thanks to this loop, what happens is that the `R1: R0`
521
+ /// constraint has lowered the universe of `R1` to `U0`, which in turn
522
+ /// means that the `R1: !1` constraint here will cause
523
+ /// `R1` to become `'static`.
524
524
fn init_free_and_bound_regions ( & mut self ) {
525
525
// Update the names (if any)
526
526
// This iterator has unstable order but we collect it all into an IndexVec
0 commit comments