Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
2.0.8, 2.1.3
-
None
Description
This Groovy script fails to compile:
@groovy.transform.CompileStatic class MyClass { static void main(String[] args) { println "Class loader: ${this.classLoader}" } } MyClass.main([] as String[])
It complains that MyClass doesn't have a classLoader property. It seems that the static type checker does not treat this correctly in the context of a static method/property/initialiser.
Attachments
Issue Links
- depends upon
-
GROOVY-6183 Errors with static attribute expression
- Closed