I have run into an issue when adding the CompileStatic AST transformation to a class via the Groovy compiler configscript argument.
- Groovy & JVM versions: Groovy Version: 2.4.7 JVM: 1.8.0_92 Vendor: Oracle Corporation OS: Linux
- Have tried Groovy versions going back to 2.4.3 and Oracle JVM 1.7.0_79
- Changing any of the following will result in no compilation error:
- Remove the source(classValidator: ...) code around ast, leaving ast(CompileStatic), in the compiler config script
- Replace the eachWithIndex call in Demo with each
- Annotate Demo with @CompileStatic and compile without --configscript
I have detailed and demoed the bug here with some code you can clone and run.