@@ -290,16 +290,14 @@ where
290290 let mplace = MemPlace { ptr, align, meta } ;
291291 let mut mplace = MPlaceTy { mplace, layout } ;
292292 // Pointer tag tracking might want to adjust the tag.
293- if M :: ENABLE_PTR_TRACKING_HOOKS {
294- let mutbl = match val. layout . ty . sty {
295- // `builtin_deref` considers boxes immutable, that's useless for our purposes
296- ty:: Ref ( _, _, mutbl) => Some ( mutbl) ,
297- ty:: Adt ( def, _) if def. is_box ( ) => Some ( hir:: MutMutable ) ,
298- ty:: RawPtr ( _) => None ,
299- _ => bug ! ( "Unexpected pointer type {}" , val. layout. ty. sty) ,
300- } ;
301- mplace. mplace . ptr = M :: tag_dereference ( self , mplace, mutbl) ?;
302- }
293+ let mutbl = match val. layout . ty . sty {
294+ // `builtin_deref` considers boxes immutable, that's useless for our purposes
295+ ty:: Ref ( _, _, mutbl) => Some ( mutbl) ,
296+ ty:: Adt ( def, _) if def. is_box ( ) => Some ( hir:: MutMutable ) ,
297+ ty:: RawPtr ( _) => None ,
298+ _ => bug ! ( "Unexpected pointer type {}" , val. layout. ty. sty) ,
299+ } ;
300+ mplace. mplace . ptr = M :: tag_dereference ( self , mplace, mutbl) ?;
303301 // Done
304302 Ok ( mplace)
305303 }
0 commit comments