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

Groovy not compatible with asm-1.5

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.0-beta-6
    • 1.0-beta-8
    • class generator
    • None

    Description

      This is no really so much a bug in Groovy as a note that ASM changed their API in 1.5, but for reasons that Groovy may be very interested in. See...
      http://www.objectweb.org/wws/arc/asm/2004-08/msg00022.html

      Basically, the new version of ClassVisitor added an "int version" parameter to the visit() method so that the bytcode version would not be hardcoded. This is probably important with JDK1.5 getting closer to release. Go here to see the change...
      http://cvs.forge.objectweb.org/cgi-bin/viewcvs.cgi/asm/src/org/objectweb/asm/ClassVisitor.java

      Might want to just bite the bullet and upgrade to asm-1.5 because if one attempts to use asm-1.5 with the latest Groovy built from CVS, one gets...

      java.lang.NoSuchMethodError: org.objectweb.asm.ClassVisitor.visit(ILjava/lang/String;Ljava/lang/String;[Ljava/lang/String;Ljava/lang/String;)V
      at org.codehaus.groovy.classgen.ReflectorGenerator.generate(ReflectorGenerator.java:85)
      at groovy.lang.MetaClass.loadReflector(MetaClass.java:2227)
      at groovy.lang.MetaClass.generateReflector(MetaClass.java:2182)
      at groovy.lang.MetaClass.checkInitialised(MetaClass.java:2129)
      at groovy.lang.MetaClassRegistry.checkInitialised(MetaClassRegistry.java:172)
      at groovy.lang.MetaClassRegistry.<init>(MetaClassRegistry.java:113)
      at groovy.lang.MetaClassRegistry.<init>(MetaClassRegistry.java:87)
      at org.codehaus.groovy.runtime.Invoker.<init>(Invoker.java:96)
      at org.codehaus.groovy.runtime.InvokerHelper.<clinit>(InvokerHelper.java:87)
      at java.lang.Class.forName0(Native Method)
      at java.lang.Class.forName(Unknown Source)
      at org.codehaus.groovy.ast.ModuleNode.class$(ModuleNode.java:230)
      at org.codehaus.groovy.ast.ModuleNode.createStatementsClass(ModuleNode.java:236)
      at org.codehaus.groovy.ast.ModuleNode.getClasses(ModuleNode.java:111)
      at org.codehaus.groovy.control.CompilationUnit.applyToPrimaryClassNodes(CompilationUnit.java:839)
      at org.codehaus.groovy.control.CompilationUnit.classgen(CompilationUnit.java:540)
      at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:446)
      at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:244)
      at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:212)
      ...
      ...
      ...

      Jake

      Attachments

        Activity

          People

            russel Dr. Russel Winder
            hoju Jacob Kjome
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: