RFR: Mark not subclassable classes final in java.base exported classes

Eirik Bjørsnøs eirbjo at gmail.com
Tue Nov 26 20:56:46 UTC 2024


On Tue, Nov 26, 2024 at 2:22 PM Eirik Bjørsnøs <eirbjo at gmail.com> wrote:

> In addition to simply adding the final modifier, the CSR suggests minor
> updates to the classes DynamicCallSiteDesc, ModuleDescriptor and
> InterfaceAddress to better express them being non-subclassable.
>

The changes to make the InterfaceAddress constructor private has been
removed from this CSR since it was not considered a specification idea.

It could still be good to consider whether this constructor can be made
private and its comment block updated to mention that the constructor is
only accessed via native code, not Java.

I filed https://bugs.openjdk.org/browse/JDK-8345074 to track this. Feedback
from someone in the network area is welcome.

Thanks,
Eirik.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/net-dev/attachments/20241126/63e75470/attachment.htm>


More information about the net-dev mailing list