about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorRalf Jung <post@ralfj.de>2020-04-05 12:11:33 +0200
committerRalf Jung <post@ralfj.de>2020-04-05 12:11:33 +0200
commite52a4519131bccc732f53ec13582016bb2b1d04a (patch)
tree6b8e35cb10d0976298dcdf4f9cc48c1930e67925 /src
parent315a3b96a4c8c793ee1161671b78fd5b0490fb9e (diff)
fix comment
Diffstat (limited to 'src')
-rw-r--r--src/librustc_mir/interpret/eval_context.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/librustc_mir/interpret/eval_context.rs b/src/librustc_mir/interpret/eval_context.rs
index 35f2aadff6a..0b182d42287 100644
--- a/src/librustc_mir/interpret/eval_context.rs
+++ b/src/librustc_mir/interpret/eval_context.rs
@@ -230,8 +230,8 @@ pub(super) fn mir_assign_valid_types<'tcx>(
 
     // Type-changing assignments can happen for (at least) two reasons:
     // 1. `&mut T` -> `&T` gets optimized from a reborrow to a mere assignment.
-    // 2. Subtyping is used. While all normal lifetimes are erased, higher-ranked lifetime
-    //    bounds with their late-bound regions are still around and can lead to type differences.
+    // 2. Subtyping is used. While all normal lifetimes are erased, higher-ranked types
+    //    with their late-bound lifetimes are still around and can lead to type differences.
     // Normalize both of them away.
     let normalize = |ty: Ty<'tcx>| {
         ty.fold_with(&mut BottomUpFolder {
@@ -241,7 +241,7 @@ pub(super) fn mir_assign_valid_types<'tcx>(
                 ty::Ref(_, pointee, _) => tcx.mk_imm_ref(tcx.lifetimes.re_erased, pointee),
                 _ => ty,
             },
-            // We just erase all late-bound regions, but this is not fully correct (FIXME):
+            // We just erase all late-bound lifetimes, but this is not fully correct (FIXME):
             // lifetimes in invariant positions could matter (e.g. through associated types).
             // We rely on the fact that layout was confirmed to be equal above.
             lt_op: |_| tcx.lifetimes.re_erased,