Eric Milles created GROOVY-11664:
------------------------------------

             Summary: STC: method call with class literals
                 Key: GROOVY-11664
                 URL: https://issues.apache.org/jira/browse/GROOVY-11664
             Project: Groovy
          Issue Type: Bug
          Components: Static Type Checker
            Reporter: Eric Milles


Consider the following:
{code:groovy}
class A {}
class B extends A {}
class C extends B {}
@groovy.transform.TypeChecked test() {
    def list = Arrays.asList(A.class, B.class, C.class)
}
test()
{code}

This fails with "Cannot call <T> java.util.Arrays#asList(T[]) with arguments 
[java.lang.Class<A>, java.lang.Class<B>, java.lang.Class<C>]"



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

Reply via email to