You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@groovy.apache.org by "Paul King (JIRA)" <ji...@apache.org> on 2019/08/12 12:57:00 UTC

[jira] [Closed] (GROOVY-9203) Anonymous inner class count is not local to enclosing type

     [ https://issues.apache.org/jira/browse/GROOVY-9203?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Paul King closed GROOVY-9203.
-----------------------------

> Anonymous inner class count is not local to enclosing type
> ----------------------------------------------------------
>
>                 Key: GROOVY-9203
>                 URL: https://issues.apache.org/jira/browse/GROOVY-9203
>             Project: Groovy
>          Issue Type: Bug
>            Reporter: Eric Milles
>            Assignee: Paul King
>            Priority: Major
>             Fix For: 3.0.0-beta-3
>
>          Time Spent: 20m
>  Remaining Estimate: 0h
>
> Consider the following:
> {code}
> class C {
>   def meth() {
>     new Object() {} // C$1
>     new Object() {} // C$2
>     new Object() {  // C$3
>       String toString() {
>         new Object() {} // C$3$4 but expect C$3$1
>       }
>     }
>     // new Object() {} here would be C$5 but expect C$4
>   }
> }
> println new C().meth()
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)