@@ -169,10 +169,10 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {
169169 ) -> Result < ( ) , ( ) > {
170170 match place {
171171 PlaceRef { local, projection : [ ] } => {
172- self . append_local_to_string ( * local, buf) ?;
172+ self . append_local_to_string ( local, buf) ?;
173173 }
174174 PlaceRef { local, projection : [ ProjectionElem :: Deref ] }
175- if self . body . local_decls [ * local] . is_ref_for_guard ( ) =>
175+ if self . body . local_decls [ local] . is_ref_for_guard ( ) =>
176176 {
177177 self . append_place_to_string (
178178 PlaceRef { local : local, projection : & [ ] } ,
@@ -182,9 +182,9 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {
182182 ) ?;
183183 }
184184 PlaceRef { local, projection : [ ProjectionElem :: Deref ] }
185- if self . body . local_decls [ * local] . is_ref_to_static ( ) =>
185+ if self . body . local_decls [ local] . is_ref_to_static ( ) =>
186186 {
187- let local_info = & self . body . local_decls [ * local] . local_info ;
187+ let local_info = & self . body . local_decls [ local] . local_info ;
188188 if let LocalInfo :: StaticRef { def_id, .. } = * local_info {
189189 buf. push_str ( & self . infcx . tcx . item_name ( def_id) . as_str ( ) ) ;
190190 } else {
@@ -307,7 +307,7 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {
307307 // FIXME Place2 Make this work iteratively
308308 match place {
309309 PlaceRef { local, projection : [ ] } => {
310- let local = & self . body . local_decls [ * local] ;
310+ let local = & self . body . local_decls [ local] ;
311311 self . describe_field_from_ty ( & local. ty , field, None )
312312 }
313313 PlaceRef { local, projection : [ proj_base @ .., elem] } => match elem {
@@ -316,7 +316,7 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {
316316 }
317317 ProjectionElem :: Downcast ( _, variant_index) => {
318318 let base_ty =
319- Place :: ty_from ( place. local , place. projection , * self . body , self . infcx . tcx )
319+ Place :: ty_from ( & place. local , place. projection , * self . body , self . infcx . tcx )
320320 . ty ;
321321 self . describe_field_from_ty ( & base_ty, field, Some ( * variant_index) )
322322 }
@@ -447,7 +447,7 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {
447447
448448 // If we didn't find an overloaded deref or index, then assume it's a
449449 // built in deref and check the type of the base.
450- let base_ty = Place :: ty_from ( deref_base. local , deref_base. projection , * self . body , tcx) . ty ;
450+ let base_ty = Place :: ty_from ( & deref_base. local , deref_base. projection , * self . body , tcx) . ty ;
451451 if base_ty. is_unsafe_ptr ( ) {
452452 BorrowedContentSource :: DerefRawPointer
453453 } else if base_ty. is_mutable_ptr ( ) {
0 commit comments