Address nits and remove unneeded pass
This commit is contained in:
parent
94414ac7bb
commit
52cc85f008
@ -496,7 +496,7 @@ fn dest_needs_borrow(place: &Place<'_>) -> bool {
|
||||
kind: TerminatorKind::Goto { target: BasicBlock::new(bb_len) }
|
||||
};
|
||||
|
||||
caller_body[callsite.bb].terminator= Some(terminator);
|
||||
caller_body[callsite.bb].terminator = Some(terminator);
|
||||
|
||||
true
|
||||
}
|
||||
|
@ -297,8 +297,6 @@ fn run_optimization_passes<'tcx>(
|
||||
&uniform_array_move_out::RestoreSubsliceArrayMoveOut::new(tcx),
|
||||
&inline::Inline,
|
||||
|
||||
// State transform requires that predecessors have been predefined
|
||||
&ensure_predecessors_cache::EnsurePredecessorsCache::new("pre-state-transform"),
|
||||
// Lowering generator control-flow and variables
|
||||
// has to happen before we do anything else to them.
|
||||
&generator::StateTransform,
|
||||
|
@ -124,11 +124,9 @@ pub fn simplify(mut self) {
|
||||
changed |= inner_changed;
|
||||
}
|
||||
|
||||
{
|
||||
let data = &mut self.basic_blocks[bb];
|
||||
data.statements.extend(new_stmts);
|
||||
data.terminator = Some(terminator);
|
||||
}
|
||||
let data = &mut self.basic_blocks[bb];
|
||||
data.statements.extend(new_stmts);
|
||||
data.terminator = Some(terminator);
|
||||
|
||||
changed |= inner_changed;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user