Details
-
Type:
Bug
-
Status: Resolved
-
Priority:
P4
-
Resolution: Fixed
-
Affects Version/s: 15
-
Fix Version/s: 16
-
Component/s: specification
-
Labels:
-
Subcomponent:
Description
Per this design discussion:
https://mail.openjdk.java.net/pipermail/amber-spec-experts/2020-May/002161.html
The consensus is that, at least until we revisit the topic, member classes of local/anonymous classes should not be allowed to use the 'sealed' modifier or to extend/implement a sealed class or interface.
The sealed-classes-jls spec change document should be updated accordingly.
https://mail.openjdk.java.net/pipermail/amber-spec-experts/2020-May/002161.html
The consensus is that, at least until we revisit the topic, member classes of local/anonymous classes should not be allowed to use the 'sealed' modifier or to extend/implement a sealed class or interface.
The sealed-classes-jls spec change document should be updated accordingly.
Attachments
Issue Links
- relates to
-
JDK-8246380 Sealed classes: prohibit member classes of local/anonymous classes
-
- Resolved
-
-
JDK-8246775 JEP 397: Sealed Classes (Second Preview)
-
- Closed
-