Implement IntoIterator for PrimaryMap.

This makes iterating through a `PrimaryMap` more consistent with
iterating through a `Vec`.
This commit is contained in:
Dan Gohman
2018-06-07 15:32:11 -07:00
parent fdf89edbfe
commit 00d7d3a774
4 changed files with 32 additions and 8 deletions

View File

@@ -88,7 +88,7 @@ impl Pressure {
};
// Get the layout of aliasing top-level register classes from the register banks.
for bank in reginfo.banks.iter() {
for bank in reginfo.banks {
let first = bank.first_toprc;
let num = bank.num_toprcs;