Skip to content

Commit 0d8a458

Browse files
committed
(&mut iter) -> iter.by_ref()
1 parent fb0e585 commit 0d8a458

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/rustc_middle/src/mir/traversal.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ pub fn reachable<'a, 'tcx>(
237237
/// Returns a `BitSet` containing all basic blocks reachable from the `START_BLOCK`.
238238
pub fn reachable_as_bitset(body: &Body<'_>) -> BitSet<BasicBlock> {
239239
let mut iter = preorder(body);
240-
(&mut iter).for_each(drop);
240+
iter.by_ref().for_each(drop);
241241
iter.visited
242242
}
243243

0 commit comments

Comments
 (0)