RFR: 8301220: Return value of toArray() of Сollection types from java.base should be trusted [v2]

Glavo duke at openjdk.org
Fri Jan 27 13:53:45 UTC 2023


> I checked the `java.base` module, and all the `Collection#toArray()` method of collections be implemented correctly.
> 
> Their return values can be trusted, so many unnecessary array duplication can be eliminated.

Glavo has updated the pull request incrementally with one additional commit since the last revision:

  Collections.isTrustedCollection

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/12212/files
  - new: https://git.openjdk.org/jdk/pull/12212/files/e0966d49..aecd79ff

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=12212&range=01
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=12212&range=00-01

  Stats: 51 lines in 8 files changed: 36 ins; 2 del; 13 mod
  Patch: https://git.openjdk.org/jdk/pull/12212.diff
  Fetch: git fetch https://git.openjdk.org/jdk pull/12212/head:pull/12212

PR: https://git.openjdk.org/jdk/pull/12212


More information about the core-libs-dev mailing list