RFR: JEP 359-Records: javadoc code

Jonathan Gibbons jonathan.gibbons at oracle.com
Wed Nov 13 23:19:24 UTC 2019


On 10/31/19 7:18 AM, Remi Forax wrote:
>> For nested classes, on the other hand, I’m not quite as sure.  The rule about
>> “nested records are implicitly static” is a little more subtle than the one
>> about finality.
> I will just add that enums have exactly the same rule, an enum is always static when nested in another class,
> so whatever we decide, it should be the same for enums.
>
> Rémi
>

To pick up on this, there's good news, bad news ;-)

Good news: the handling of the static modifier on nested classes is the 
same for "enum" and "static".

Bad news (but should be easy to fix): nested records do not show up in 
the enclosing class.

-- Jon

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.java.net/pipermail/compiler-dev/attachments/20191113/db4af992/attachment-0001.html>


More information about the compiler-dev mailing list