Move predecessors from Body to BasicBlocks

This commit is contained in:
Tomasz Miąsko 2022-07-05 00:00:00 +00:00
parent e34ee2484b
commit cac25cde18

View File

@ -161,7 +161,7 @@ impl<'tcx> LateLintPass<'tcx> for RedundantClone {
// `arg` is a reference as it is `.deref()`ed in the previous block.
// Look into the predecessor block and find out the source of deref.
let ps = &mir.predecessors()[bb];
let ps = &mir.basic_blocks.predecessors()[bb];
if ps.len() != 1 {
continue;
}