RFR: 8300237: Minor improvements in MethodHandles [v4]
Sergey Tsypanov
stsypanov at openjdk.org
Wed Jan 18 07:32:58 UTC 2023
On Tue, 17 Jan 2023 22:28:50 GMT, Claes Redestad <redestad at openjdk.org> wrote:
>> Sergey Tsypanov has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Merge map() calls
>
> src/java.base/share/classes/java/lang/invoke/MethodHandles.java line 6752:
>
>> 6750: .map(MethodHandle::type)
>> 6751: .filter(t -> t.parameterCount() > skipSize)
>> 6752: .max(Comparator.comparing(MethodType::parameterCount))
>
> @forax suggested `Comparator.comparingInt` here, which may or may not help avoid some boxing.
Nice point, done!
-------------
PR: https://git.openjdk.org/jdk/pull/12025
More information about the core-libs-dev
mailing list