Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
alter
retain
's closure signature from &usize
to usize
`retain`'s signature is based on the signature for other collections, which provide a borrowed value. In our case, an owned usize is more convenient in many ways and this change provides that. Matklad pointed out that `vector`'s signature is considered a bug and `FnMut(&mut T)` is preferred. For mset, which has invariants that must be enforced at runtime, I don't think we want `retain` to alter the multiplicity. Instead we go with an owned usize for simplicity and consistency with the rest of the interface
- Loading branch information