-
Bug
-
Resolution: Duplicate
-
P3
-
22, 23
-
None
-
generic
-
generic
JavaDoc shows a `sealed` modifier on methods annotated with `jdk.internal.javac.Restricted`.
Example: https://download.java.net/java/early_access/jdk22/docs/api/java.base/java/lang/foreign/AddressLayout.html#withTargetLayout(java.lang.foreign.MemoryLayout)
The likely reason is that `RESTRICTED` and `SEALED` constants have the same value in `com.sun.tools.javac.code.Flags`, though the former is meant for methods and the latter for classes.
This issue was reported on a github PR: https://github.com/openjdk/jdk/pull/16188#issuecomment-1925960367
Example: https://download.java.net/java/early_access/jdk22/docs/api/java.base/java/lang/foreign/AddressLayout.html#withTargetLayout(java.lang.foreign.MemoryLayout)
The likely reason is that `RESTRICTED` and `SEALED` constants have the same value in `com.sun.tools.javac.code.Flags`, though the former is meant for methods and the latter for classes.
This issue was reported on a github PR: https://github.com/openjdk/jdk/pull/16188#issuecomment-1925960367
- duplicates
-
JDK-8325217 MethodSymbol.getModifiers() returns SEALED for restricted methods
-
- Resolved
-