RFR: JDK-8283416: Update java.lang.invoke.MethodHandle to use sealed classes

Mandy Chung mchung at openjdk.java.net
Mon Mar 21 18:20:27 UTC 2022


On Mon, 21 Mar 2022 06:08:32 GMT, Athijegannathan Sundararajan <sundar at openjdk.org> wrote:

> $ javac com/acme/*.java
>
> is fine. Am I missing something?

If you make P.Q private, it will fail the compilation.

To make `DelegatingMethodHandle` a sealed class, we could make `AsVarargsCollector` and `WrappedMember` package-private classes.

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

PR: https://git.openjdk.java.net/jdk/pull/7881


More information about the core-libs-dev mailing list