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

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

eric-milles opened a new pull request, #2205:
URL: https://github.com/apache/groovy/pull/2205

   Support interface default method making reference to super interface 
constant.




> interface extends interface and uses static field in default method
> -------------------------------------------------------------------
>
>                 Key: GROOVY-11639
>                 URL: https://issues.apache.org/jira/browse/GROOVY-11639
>             Project: Groovy
>          Issue Type: Bug
>    Affects Versions: 5.0.0-alpha-12
>            Reporter: Eric Milles
>            Assignee: Eric Milles
>            Priority: Minor
>
> Consider the following:
> {code:groovy}
> interface I {
>   String FOO = 'foo'
> }
> interface J extends I {
>   default String dm() {
>     FOO + 'bar'
>   }
> }
> class C implements J {
>   def m() {
>     dm() + 'baz'
>   }
> }
> assert new C().m() == 'foobarbaz'
> {code}
> {code}
> groovy.lang.MissingPropertyException: No such property: FOO for class: C
>       at J.dm(Groovy10312.groovy:6)
>       at C.m(Groovy10312.groovy:11)
>       at Groovy11xxx.run(Groovy10312.groovy:15)
> {code}



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

Reply via email to