Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-5912

Static compilation: Groovy doesn't fail compilation when accessing package scope methods, but fails at runtime

    XMLWordPrintableJSON

Details

    Description

      If you set a package scoped property from another package, this compiles but at runtime you get errors like:

      tried to access method org.codehaus.groovy.grails.core.io.PluginPathAwareFileSystemResourceLoader.setSearchLocations(Ljava/util/Collection;)V from class org.codehaus.groovy.grails.project.loader.GrailsProjectLoader
      java.lang.IllegalAccessError: tried to access method org.codehaus.groovy.grails.core.io.PluginPathAwareFileSystemResourceLoader.setSearchLocations(Ljava/util/Collection;)V from class org.codehaus.groovy.grails.project.loader.GrailsProjectLoader
      
      

      This should not happen and be a compilation error

      Attachments

        Activity

          People

            daniel_sun Daniel Sun
            graemerocher Graeme Rocher
            Votes:
            2 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: