about summary refs log tree commit diff
diff options
context:
space:
mode:
authorBastian Kauschke <bastian_kauschke@hotmail.de>2020-05-08 21:10:33 +0200
committerBastian Kauschke <bastian_kauschke@hotmail.de>2020-05-17 11:06:35 +0200
commit0f7bf5d9e11189dfbc10bc2acba653c4893c9b6c (patch)
tree970c4de0b699a718b2eee85c56d71f2d08e3ad5b
parent443ae838742350a93326ede1f4ad7429238da644 (diff)
downloadrust-0f7bf5d9e11189dfbc10bc2acba653c4893c9b6c.tar.gz
rust-0f7bf5d9e11189dfbc10bc2acba653c4893c9b6c.zip
add docs
-rw-r--r--src/librustc_middle/ty/relate.rs2
-rw-r--r--src/librustc_mir/borrow_check/type_check/relate_tys.rs2
-rw-r--r--src/librustc_trait_selection/traits/object_safety.rs2
-rw-r--r--src/librustc_typeck/check/mod.rs2
4 files changed, 5 insertions, 3 deletions
diff --git a/src/librustc_middle/ty/relate.rs b/src/librustc_middle/ty/relate.rs
index 621a4efc6cc..0ae62b0e813 100644
--- a/src/librustc_middle/ty/relate.rs
+++ b/src/librustc_middle/ty/relate.rs
@@ -431,7 +431,7 @@ pub fn super_relate_tys<R: TypeRelation<'tcx>>(
             let t = relation.relate(&a_t, &b_t)?;
             match relation.relate(&sz_a, &sz_b) {
                 Ok(sz) => Ok(tcx.mk_ty(ty::Array(t, sz))),
-                // FIXME(lazy_normalization_consts) Implement improved diagnostics for mismatched array
+                // FIXME(#72219) Implement improved diagnostics for mismatched array
                 // length?
                 Err(err) if relation.tcx().features().const_generics => Err(err),
                 Err(err) => {
diff --git a/src/librustc_mir/borrow_check/type_check/relate_tys.rs b/src/librustc_mir/borrow_check/type_check/relate_tys.rs
index c3b0bd82398..7ff12820db8 100644
--- a/src/librustc_mir/borrow_check/type_check/relate_tys.rs
+++ b/src/librustc_mir/borrow_check/type_check/relate_tys.rs
@@ -99,6 +99,8 @@ impl TypeRelatingDelegate<'tcx> for NllTypeRelatingDelegate<'_, '_, 'tcx> {
         }
     }
 
+    // We don't have to worry about the equality of consts during borrow checking
+    // as consts always have a static lifetime.
     fn const_equate(&mut self, _a: &'tcx Const<'tcx>, _b: &'tcx Const<'tcx>) {}
 
     fn normalization() -> NormalizationStrategy {
diff --git a/src/librustc_trait_selection/traits/object_safety.rs b/src/librustc_trait_selection/traits/object_safety.rs
index a34006dd4fc..1bfcacd6ccd 100644
--- a/src/librustc_trait_selection/traits/object_safety.rs
+++ b/src/librustc_trait_selection/traits/object_safety.rs
@@ -771,7 +771,7 @@ fn contains_illegal_self_type_reference<'tcx>(
         }
 
         fn visit_const(&mut self, _c: &ty::Const<'tcx>) -> bool {
-            // FIXME Look into the unevaluated constants for object safety violations.
+            // FIXME(#72219) Look into the unevaluated constants for object safety violations.
             // Do not walk substitutions of unevaluated consts, as they contain `Self`, even
             // though the const expression doesn't necessary use it. Currently type variables
             // inside array length expressions are forbidden, so they can't break the above
diff --git a/src/librustc_typeck/check/mod.rs b/src/librustc_typeck/check/mod.rs
index 02b42284e6d..d72c74e4188 100644
--- a/src/librustc_typeck/check/mod.rs
+++ b/src/librustc_typeck/check/mod.rs
@@ -1651,7 +1651,7 @@ fn check_opaque_for_inheriting_lifetimes(tcx: TyCtxt<'tcx>, def_id: LocalDefId,
 
         fn visit_const(&mut self, c: &'tcx ty::Const<'tcx>) -> bool {
             if let ty::ConstKind::Unevaluated(..) = c.val {
-                // FIXME(lazy_normalization_consts) We currenctly don't detect lifetimes within substs
+                // FIXME(#72219) We currenctly don't detect lifetimes within substs
                 // which would violate this check. Even though the particular substitution is not used
                 // within the const, this should still be fixed.
                 return false;