On Thu, 26 Jan 2023 06:46:16 GMT, Glavo <d...@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.
What about Collections.synchronizedCollection and other methods that may wrap/delagete to collections from other modules? ------------- PR: https://git.openjdk.org/jdk/pull/12212