You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@groovy.apache.org by "Daniil Ovchinnikov (JIRA)" <ji...@apache.org> on 2017/04/12 17:27:41 UTC

[jira] [Created] (GROOVY-8154) Parenthesized class literal with subscript operator

Daniil Ovchinnikov created GROOVY-8154:
------------------------------------------

             Summary: Parenthesized class literal with subscript operator
                 Key: GROOVY-8154
                 URL: https://issues.apache.org/jira/browse/GROOVY-8154
             Project: Groovy
          Issue Type: Bug
    Affects Versions: 2.4.10, 2.5.0-alpha-1
            Reporter: Daniil Ovchinnikov


Current behaviour:
{code}
assert (String.class)[] == String[].class
{code}

Expected {{(String.class)[]}} should fail with {{MissingMethodException: No signature of method: static java.lang.String.getAt() is applicable for argument types: (ArrayList) values: [[]]}} just like:
{code}
def a = String.class
a[] // MissingMethodException
{code}



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)