[
https://issues.apache.org/jira/browse/GROOVY-11195?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Eric Milles resolved GROOVY-11195.
----------------------------------
Fix Version/s: 3.0.20
Resolution: Fixed
https://github.com/apache/groovy/commit/26af4c1ac61c2c9a7ef842c9a5dda92b5bbd0d77
> STC: false positive for Class method called from static context
> ---------------------------------------------------------------
>
> Key: GROOVY-11195
> URL: https://issues.apache.org/jira/browse/GROOVY-11195
> Project: Groovy
> Issue Type: Bug
> Affects Versions: 3.0.19
> Reporter: Eric Milles
> Assignee: Eric Milles
> Priority: Major
> Fix For: 3.0.20
>
>
> Consider the following:
> {code:groovy}
> @TypeChecked
> class C {
> static String typeName = this.getName() // instance method from Class
> }
> {code}
> This emits error "Non-static method Class#getName cannot be called from a
> static context".
--
This message was sent by Atlassian Jira
(v8.20.10#820010)