-
Notifications
You must be signed in to change notification settings - Fork 10.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make
UnmodifiableMultiset.removeIf(Predicate)
unsupported
Even if there's nothing to remove, `removeIf(Predicate)` should throw an `UnsupportedOperationException`. This is theoretically an incompatible change, in that some existing code might have been calling `removeIf` with a predicate that is never true. None of Google's internal uses show this problem in tests. Fixes #6702. Closes #6703. RELNOTES=`Multisets.unmodifiableMultiset(set).removeIf(predicate)` now throws an exception always, even if nothing matches `predicate`. PiperOrigin-RevId: 564750701
- Loading branch information
Showing
3 changed files
with
15 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters