I'm fixing this along with a couple intertwined issues.

1. Add Map.Entry::copyOf as an idempotent copy operation.

2. Clarify that AbstractMap.SimpleImmutableEntry is itself unmodifiable (not 
really immutable) but that subclasses can be modifiable.

3. Clarify some confusing, historical wording about Map.Entry instances being 
obtainable only via iteration of a Map's entry-set view. This was never really 
true, since anyone could implement the Map.Entry interface, and it certainly 
was not true since JDK 1.6 when SimpleEntry and SimpleImmutableEntry were added.

-------------

Commit messages:
 - More spec and test tweaks.
 - Fix up tests.
 - Spec wordsmithing.
 - Update specs. Add basic tests.
 - 8199318: add idempotent copy operation for Map.Entry

Changes: https://git.openjdk.java.net/jdk/pull/4295/files
 Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=4295&range=00
  Issue: https://bugs.openjdk.java.net/browse/JDK-8199318
  Stats: 141 lines in 3 files changed: 120 ins; 2 del; 19 mod
  Patch: https://git.openjdk.java.net/jdk/pull/4295.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/4295/head:pull/4295

PR: https://git.openjdk.java.net/jdk/pull/4295

Reply via email to