Description
Attaching a zip that contains the example to reproduce the issue.
The scenario is this: From my Ant script, I am executing a groovy script (One.groovy), which depends on another script, Two.groovy (which has a compilation error - it refers to a non-existing class FFile).
The problem is that instead of telling me anything about FFile class's non-existence, the groovy compiler gives a not-so-useful error message that looks like below:
...\bug_report\build.xml:11: BUG! exception in phase 'semantic analysis' in source unit '...\bug_report\src\One.groovy' The lookup for Two caused a failed compilaton. There should not have been any compilation from this call. at org.codehaus.groovy.control.ClassNodeResolver.tryAsLoaderClassOrScript(ClassNodeResolver.java:188) at org.codehaus.groovy.control.ClassNodeResolver.findClassNode(ClassNodeResolver.java:168) at org.codehaus.groovy.control.ClassNodeResolver.resolveName(ClassNodeResolver.java:124) at org.codehaus.groovy.control.ResolveVisitor.resolveToOuter(ResolveVisitor.java:617) at org.codehaus.groovy.control.ResolveVisitor.resolve(ResolveVisitor.java:269) at org.codehaus.groovy.control.ResolveVisitor.resolve(ResolveVisitor.java:237) at org.codehaus.groovy.control.ResolveVisitor.resolveOrFail(ResolveVisitor.java:221) at org.codehaus.groovy.control.ResolveVisitor.resolveOrFail(ResolveVisitor.java:233) at org.codehaus.groovy.control.ResolveVisitor.transformConstructorCallExpression(ResolveVisitor.java:988) ... ...
It'll do better to include some information about the underlying exception.
"BUG! exception in phase 'semantic analysis' in source unit '...\One.groovy'" is not much use.