]> git.lizzy.rs Git - rust.git/blobdiff - compiler/rustc_mir/src/transform/simplify.rs
make `super_projection` take a `PlaceRef`
[rust.git] / compiler / rustc_mir / src / transform / simplify.rs
index b7c9a3a8688ec7907c976b0b5363dffbe09c09f4..d9abfec85c9e7643e4d68ad0118d05781dfc5b18 100644 (file)
@@ -61,7 +61,7 @@ fn name(&self) -> Cow<'_, str> {
     }
 
     fn run_pass(&self, _tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
-        debug!("SimplifyCfg({:?}) - simplifying {:?}", self.label, body);
+        debug!("SimplifyCfg({:?}) - simplifying {:?}", self.label, body.source);
         simplify_cfg(body);
     }
 }
@@ -414,8 +414,7 @@ fn visit_lhs(&mut self, place: &Place<'tcx>, location: Location) {
         } else {
             // A definition. Although, it still might use other locals for indexing.
             self.super_projection(
-                place.local,
-                &place.projection,
+                place.as_ref(),
                 PlaceContext::MutatingUse(MutatingUseContext::Projection),
                 location,
             );