[ 
https://issues.apache.org/jira/browse/GROOVY-11597?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17941527#comment-17941527
 ] 

ASF GitHub Bot commented on GROOVY-11597:
-----------------------------------------

daniellansun merged PR #2175:
URL: https://github.com/apache/groovy/pull/2175




> STC: element type of enum class
> -------------------------------
>
>                 Key: GROOVY-11597
>                 URL: https://issues.apache.org/jira/browse/GROOVY-11597
>             Project: Groovy
>          Issue Type: Bug
>          Components: Static Type Checker
>            Reporter: Eric Milles
>            Assignee: Eric Milles
>            Priority: Major
>
> Consider the following:
> {code:groovy}
> @TypeChecked test() {
>   for (ts in Thread.State) {
>     println "${ts.ordinal()}: ${ts.name()}"
>   }
> }
> {code}
> Without STC, this runs and prints out the enum values of {{Thread.State}}.  
> With STC, it errors on "ts.name()" and "ts.ordinal()".



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to