Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
3.12.0
-
None
-
JDK 16
Description
In Java 16, many classes in java.base module are not able to be made accessible due to access restrictions on the module. An example is ArrayList.
In ToStringBuilderTest.testReflectionHierarchyArrayList(), the test fails with the following error:
java.lang.reflect.InaccessibleObjectException: Unable to make field private static final java.lang.Object[] java.util.ArrayList.DEFAULTCAPACITY_EMPTY_ELEMENTDATA accessible: module java.base does not "opens java.util" to unnamed module @3339ad8e
This is causing build failures for all open PRs.