From cbde62c2cc5cfcbbb39bfc1e3ef61016a1693298 Mon Sep 17 00:00:00 2001 From: gaurikholkar Date: Sat, 7 Apr 2018 14:36:29 +0530 Subject: [PATCH] fix tidy errors --- src/librustc_mir/borrow_check/mod.rs | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/librustc_mir/borrow_check/mod.rs b/src/librustc_mir/borrow_check/mod.rs index db7427ddae59..e3714802e2a9 100644 --- a/src/librustc_mir/borrow_check/mod.rs +++ b/src/librustc_mir/borrow_check/mod.rs @@ -1578,14 +1578,10 @@ impl<'cx, 'gcx, 'tcx> MirBorrowckCtxt<'cx, 'gcx, 'tcx> { Reservation(WriteKind::Mutate) | Write(WriteKind::Mutate) => { if let Err(place_err) = self.is_mutable(place, is_local_mutation_allowed) { error_reported = true; - let mut err_info = None; - match *place_err { - Place::Projection(box Projection { ref base, elem:ProjectionElem::Deref}) => { - match *base { Place::Local(local) => { let locations = self.mir.find_assignments(local); @@ -1594,8 +1590,7 @@ impl<'cx, 'gcx, 'tcx> MirBorrowckCtxt<'cx, 'gcx, 'tcx> { self.get_secondary_err_msg(base) } else { self.get_default_err_msg(place) - }; - + }; err_info = Some(( self.mir.source_info(locations[0]).span, "consider changing this to be a \