RFR: 8301220: Return value of toArray() of Сollection types from java.base should be trusted [v2]
Rémi Forax
forax at openjdk.org
Sat Jan 28 15:37:16 UTC 2023
On Fri, 27 Jan 2023 13:53:45 GMT, Glavo <duke at openjdk.org> wrote:
>> 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
This may change the startup time a lot because initializing the annotation parser (and the factory around) and creating the annotations is quite slow.
-------------
PR: https://git.openjdk.org/jdk/pull/12212
More information about the core-libs-dev
mailing list