@@ -165,6 +165,7 @@ impl<'tcx> MirPass<'tcx> for DestinationPropagation {
165
165
fn run_pass ( & self , tcx : TyCtxt < ' tcx > , body : & mut Body < ' tcx > ) {
166
166
let def_id = body. source . def_id ( ) ;
167
167
let mut allocations = Allocations :: default ( ) ;
168
+ let mut write_info = WriteInfo :: default ( ) ;
168
169
trace ! ( func = ?tcx. def_path_str( def_id) ) ;
169
170
170
171
let borrowed = rustc_mir_dataflow:: impls:: borrowed_locals ( body) ;
@@ -205,7 +206,7 @@ impl<'tcx> MirPass<'tcx> for DestinationPropagation {
205
206
& mut candidates,
206
207
& points,
207
208
& live,
208
- & mut allocations . write_info ,
209
+ & mut write_info,
209
210
body,
210
211
) ;
211
212
@@ -262,7 +263,6 @@ impl<'tcx> MirPass<'tcx> for DestinationPropagation {
262
263
struct Allocations {
263
264
candidates : FxIndexMap < Local , Vec < Local > > ,
264
265
candidates_reverse : FxIndexMap < Local , Vec < Local > > ,
265
- write_info : WriteInfo ,
266
266
// PERF: Do this for `MaybeLiveLocals` allocations too.
267
267
}
268
268
@@ -364,7 +364,7 @@ struct FilterInformation<'a, 'alloc, 'tcx> {
364
364
points : & ' a DenseLocationMap ,
365
365
live : & ' a SparseIntervalMatrix < Local , PointIndex > ,
366
366
candidates : & ' a mut Candidates < ' alloc > ,
367
- write_info : & ' alloc mut WriteInfo ,
367
+ write_info : & ' a mut WriteInfo ,
368
368
at : Location ,
369
369
}
370
370
@@ -468,7 +468,7 @@ impl<'a, 'alloc, 'tcx> FilterInformation<'a, 'alloc, 'tcx> {
468
468
candidates : & mut Candidates < ' alloc > ,
469
469
points : & DenseLocationMap ,
470
470
live : & SparseIntervalMatrix < Local , PointIndex > ,
471
- write_info : & ' alloc mut WriteInfo ,
471
+ write_info : & mut WriteInfo ,
472
472
body : & Body < ' tcx > ,
473
473
) {
474
474
let mut this = FilterInformation {
0 commit comments