Skip to content

Commit 017620f

Browse files
committed
Use Place directly in peek_at, it's Copy
1 parent 947c1dc commit 017620f

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/librustc_mir/transform/rustc_peek.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ pub fn sanity_check_via_rustc_peek<'tcx, A>(
127127
let loc = Location { block: bb, statement_index };
128128
cursor.seek_before(loc);
129129
let state = cursor.get();
130-
results.analysis.peek_at(tcx, place, state, call);
130+
results.analysis.peek_at(tcx, *place, state, call);
131131
}
132132

133133
_ => {
@@ -231,7 +231,7 @@ pub trait RustcPeekAt<'tcx>: Analysis<'tcx> {
231231
fn peek_at(
232232
&self,
233233
tcx: TyCtxt<'tcx>,
234-
place: &mir::Place<'tcx>,
234+
place: mir::Place<'tcx>,
235235
flow_state: &BitSet<Self::Idx>,
236236
call: PeekCall,
237237
);
@@ -244,7 +244,7 @@ where
244244
fn peek_at(
245245
&self,
246246
tcx: TyCtxt<'tcx>,
247-
place: &mir::Place<'tcx>,
247+
place: mir::Place<'tcx>,
248248
flow_state: &BitSet<Self::Idx>,
249249
call: PeekCall,
250250
) {
@@ -268,7 +268,7 @@ impl<'tcx> RustcPeekAt<'tcx> for MaybeMutBorrowedLocals<'_, 'tcx> {
268268
fn peek_at(
269269
&self,
270270
tcx: TyCtxt<'tcx>,
271-
place: &mir::Place<'tcx>,
271+
place: mir::Place<'tcx>,
272272
flow_state: &BitSet<Local>,
273273
call: PeekCall,
274274
) {

0 commit comments

Comments
 (0)