Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8168317

[JVMCI] use reflection instead of jdk 9 Module API in Services.java

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: 9
    • Fix Version/s: 9
    • Component/s: hotspot
    • Labels:
    • Subcomponent:
    • Resolved In Build:
      b146
    • CPU:
      generic
    • OS:
      generic

      Description

      When Graal is built as part of JDK it requires first to build an annotation processor using boot jdk 8.
      After JDK-8167180 changes Services class is used by annotation processor but the code is using jdk 9 Module API and it can't be compiled with jdk 8:

      hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/Services.java:25: error: cannot find symbol
      import java.lang.reflect.Module;
                              ^
        symbol: class Module
        location: package java.lang.reflect
      hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/Services.java:55: error: cannot find symbol
              Module jvmci = Services.class.getModule();
              ^
        symbol: class Module
        location: class Services
      hotspot/src/jdk.vm.ci/share/classes/jdk.vm.ci.services/src/jdk/vm/ci/services/Services.java:55: error: cannot find symbol
              Module jvmci = Services.class.getModule();
                                           ^
        symbol: method getModule()
        location: variable class of type Class<Services>


      Use reflection instead of Module API.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                kvn Vladimir Kozlov
                Reporter:
                kvn Vladimir Kozlov
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: