Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open jdk.internal.misc to UNNAMED module in tests #108

Merged
merged 1 commit into from
Jul 22, 2018

Conversation

gayanW
Copy link
Collaborator

@gayanW gayanW commented Jul 20, 2018

This opens java.base/jdk.internal.misc to the UNNAMED module (in junit ant target --test), so to prevent:

[junit] java.lang.IllegalAccessError: class gov.nasa.jpf.vm.JPF_java_util_Random (in unnamed module)
        cannot access class jdk.internal.misc.Unsafe (in module java.base)
        because module java.base does not export jdk.internal.misc to unnamed module

AND:

[junit] gov.nasa.jpf.JPFException: cannot access java.util.Random
        internals: java.lang.reflect.InaccessibleObjectException: Unable to make
        field private static final jdk.internal.misc.Unsafe
        jdk.internal.misc.Unsafe.theUnsafe accessible: module java.base does not
        "opens jdk.internal.misc" to unnamed module

Fixes: #107

This opens java.base/jdk.internal.misc to the UNNAMED module (in junit
ant target --test), so to prevent:

    [junit] java.lang.IllegalAccessError: class gov.nasa.jpf.vm.JPF_java_util_Random (in unnamed module @0x9bd0fa6)
            cannot access class jdk.internal.misc.Unsafe (in module java.base)
            because module java.base does not export jdk.internal.misc to unnamed module @0x9bd0fa6

AND:

    [junit] gov.nasa.jpf.JPFException: cannot access java.util.Random
            internals: java.lang.reflect.InaccessibleObjectException: Unable to make
            field private static final jdk.internal.misc.Unsafe
            jdk.internal.misc.Unsafe.theUnsafe accessible: module java.base does not
            "opens jdk.internal.misc" to unnamed module @16f7b4af
@cyrille-artho cyrille-artho merged commit df8c87d into javapathfinder:java-10 Jul 22, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants