Use successor_within_block helper

This commit is contained in:
Santiago Pastorino 2018-11-20 15:26:01 -03:00
parent f66e4697ae
commit cbc865defd
No known key found for this signature in database
GPG key ID: 88C941CDA1D46432

View file

@ -65,10 +65,7 @@ impl<'cx, 'gcx, 'tcx> UseFinder<'cx, 'gcx, 'tcx> {
None => {
if p.statement_index < block_data.statements.len() {
queue.push_back(Location {
statement_index: p.statement_index + 1,
..p
});
queue.push_back(p.successor_within_block());
} else {
queue.extend(
block_data