On Tue, 17 Jan 2023 21:24:34 GMT, Sergey Tsypanov <stsypa...@openjdk.org> wrote:
>> - `MethodType.ptypes()` can be used instead of `MethodType.parameterList()` >> when we don't need a copy >> - comparison of two lists can be done without `Stream.reduce()` > > Sergey Tsypanov has updated the pull request incrementally with one > additional commit since the last revision: > > Merge map() calls LGTM 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. ------------- Marked as reviewed by redestad (Reviewer). PR: https://git.openjdk.org/jdk/pull/12025