Address review feedback: don't bother skipping reservations paired with activations.
This commit is contained in:
parent
b75248ef4e
commit
b0421fa7de
1 changed files with 0 additions and 10 deletions
|
|
@ -1951,16 +1951,6 @@ impl<'cx, 'gcx, 'tcx> MirBorrowckCtxt<'cx, 'gcx, 'tcx> {
|
|||
// borrows of P, P.a.b, etc.
|
||||
let mut elems_incoming = flow_state.borrows.elems_incoming();
|
||||
while let Some(i) = elems_incoming.next() {
|
||||
// Skip any reservation that has a corresponding current
|
||||
// activation. This way, the traversal will visit each
|
||||
// borrow_index at most once.
|
||||
if let Some(j) = elems_incoming.peek() {
|
||||
if i.is_reservation() && j.is_activation() {
|
||||
assert_eq!(i.borrow_index(), j.borrow_index());
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
let borrowed = &data[i.borrow_index()];
|
||||
|
||||
if self.places_conflict(&borrowed.borrowed_place, place, access) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue