The diagnostics are consistently emitted for different configurations of --release.
cat A.java
class A {
sun.misc.Unsafe theUnsafe;
}
$JAVA21_HOME/bin/java -fullversion
openjdk full version "21.0.2+13-58"
$JAVA11_HOME/bin/java -fullversion
openjdk full version "11.0.16+8"
$JAVA21_HOME/bin/javac --system $JAVA21_HOME A.java
A.java:2: warning: Unsafe is internal proprietary API and may be removed in a future release
sun.misc.Unsafe theUnsafe;
^
1 warning
$JAVA21_HOME/bin/javac --system $JAVA11_HOME A.java
...
no diagnostics
- causes
-
JDK-8349058 'internal proprietary API' warnings make javac warnings unusable
-
- Resolved
-
-
JDK-8349056 internal proprietary API warnings for sun.misc.Signal are not actionable
-
- Closed
-
-
JDK-8349944 [JMH] sun.misc.UnsafeOps cannot access class jdk.internal.misc.Unsafe
-
- New
-
- clones
-
JDK-8331081 'internal proprietary API' diagnostics if --system is configured to an earlier JDK version
-
- Closed
-
- is cloned by
-
JDK-8349846 [REDO] [REDO] 'internal proprietary API' diagnostics if --system is configured to an earlier JDK version
-
- Open
-
- relates to
-
JDK-8343770 Build fails due to use of sun.misc.Unsafe in LoopOverRandom
-
- Closed
-
- links to
-
Commit(master) openjdk/jdk/839de82c
-
Review(master) openjdk/jdk/19397