about summary refs log tree commit diff
diff options
context:
space:
mode:
authorAman Arora <me@aman-arora.com>2021-01-29 16:25:01 -0500
committerAman Arora <me@aman-arora.com>2021-01-29 16:25:01 -0500
commit0f4bab246b341b5d67ba1c01d81c4822f96dd878 (patch)
tree2608efb4946ce17fbb93882ac994f2073512bd0d
parentfadf03ee1bbe238ff5a46e60550a70470da492af (diff)
downloadrust-0f4bab246b341b5d67ba1c01d81c4822f96dd878.tar.gz
rust-0f4bab246b341b5d67ba1c01d81c4822f96dd878.zip
Fixme for closure origin when reborrow is implemented
-rw-r--r--compiler/rustc_typeck/src/check/upvar.rs7
1 files changed, 3 insertions, 4 deletions
diff --git a/compiler/rustc_typeck/src/check/upvar.rs b/compiler/rustc_typeck/src/check/upvar.rs
index 38330d5a49a..f039445bf77 100644
--- a/compiler/rustc_typeck/src/check/upvar.rs
+++ b/compiler/rustc_typeck/src/check/upvar.rs
@@ -184,10 +184,9 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
                 let origin = if self.tcx.features().capture_disjoint_fields {
                     origin
                 } else {
-                    // FIXME(project-rfc-2229#26): Once rust-lang#80092 is merged, we should restrict the
-                    // precision of origin as well. Otherwise, this will cause issues when project-rfc-2229#26
-                    // is fixed as we might see Index projections in the origin, which we can't print because
-                    // we don't store enough information.
+                    // FIXME(project-rfc-2229#31): Once the changes to support reborrowing are
+                    //                             made, make sure we are selecting and restricting
+                    //                             the origin correctly.
                     (origin.0, Place { projections: vec![], ..origin.1 })
                 };