[ https://issues.apache.org/jira/browse/GROOVY-7922?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
John Wagenleitner resolved GROOVY-7922. --------------------------------------- Resolution: Fixed Assignee: John Wagenleitner Fix Version/s: 2.4.8 Proposed PR merged. > Static type checking not strict enough in the presence of ambiguous method > matching > ----------------------------------------------------------------------------------- > > Key: GROOVY-7922 > URL: https://issues.apache.org/jira/browse/GROOVY-7922 > Project: Groovy > Issue Type: Bug > Components: Static Type Checker > Reporter: Paul King > Assignee: John Wagenleitner > Fix For: 2.4.8 > > > This example: > {code} > import groovy.transform.CompileStatic > interface FooA {} > interface FooB {} > class FooAB implements FooA, FooB {} > @CompileStatic > class TestGroovy { > static void test() { println new TestGroovy().foo(new FooAB()) } > def foo(FooB x) { 43 } > def foo(FooA x) { 42 } > } > TestGroovy.test() > {code} > Should probably throw some kind of ambiguous method error during compilation > to match Java (and dynamic Groovy's runtime error). -- This message was sent by Atlassian JIRA (v6.3.4#6332)