@@ -50,8 +50,8 @@ impl<T: MayLeak> MayLeak for MemoryKind<T> {
5050impl < T : fmt:: Display > fmt:: Display for MemoryKind < T > {
5151 fn fmt ( & self , f : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
5252 match self {
53- MemoryKind :: Stack => write ! ( f , "stack variable" ) ,
54- MemoryKind :: CallerLocation => write ! ( f , "caller location" ) ,
53+ MemoryKind :: Stack => f . write_str ( "stack variable" ) ,
54+ MemoryKind :: CallerLocation => f . write_str ( "caller location" ) ,
5555 MemoryKind :: Machine ( m) => write ! ( f, "{}" , m) ,
5656 }
5757 }
@@ -893,7 +893,7 @@ impl<'a, 'mir, 'tcx, M: Machine<'mir, 'tcx>> std::fmt::Debug for DumpAllocs<'a,
893893 // global alloc
894894 match self . ecx . tcx . try_get_global_alloc ( id) {
895895 Some ( GlobalAlloc :: Memory ( alloc) ) => {
896- write ! ( fmt, " (unchanged global, " ) ?;
896+ fmt. write_str ( " (unchanged global, " ) ?;
897897 write_allocation_track_relocs (
898898 & mut * fmt,
899899 * self . ecx . tcx ,
@@ -914,7 +914,7 @@ impl<'a, 'mir, 'tcx, M: Machine<'mir, 'tcx>> std::fmt::Debug for DumpAllocs<'a,
914914 write ! ( fmt, " (static: {})" , self . ecx. tcx. def_path_str( did) ) ?;
915915 }
916916 None => {
917- write ! ( fmt, " (deallocated)" ) ?;
917+ fmt. write_str ( " (deallocated)" ) ?;
918918 }
919919 }
920920 }
0 commit comments