You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@groovy.apache.org by "Shil Sinha (JIRA)" <ji...@apache.org> on 2015/12/05 06:56:10 UTC

[jira] [Resolved] (GROOVY-7694) Results of spread safe method calls should be stored in temporary variables

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

Shil Sinha resolved GROOVY-7694.
--------------------------------
       Resolution: Fixed
    Fix Version/s: 2.4.6

> Results of spread safe method calls should be stored in temporary variables
> ---------------------------------------------------------------------------
>
>                 Key: GROOVY-7694
>                 URL: https://issues.apache.org/jira/browse/GROOVY-7694
>             Project: Groovy
>          Issue Type: Bug
>          Components: Static compilation
>    Affects Versions: 2.4.5
>            Reporter: Shil Sinha
>            Assignee: Shil Sinha
>            Priority: Minor
>             Fix For: 2.4.6
>
>
> Currently, the following code throws an NPE during class generation because the static compiler creates variables of the form "spreadresultX" to store the results of spread safe method calls. See GROOVY-7656 for the original discussion.
> {code}
> @groovy.transform.CompileStatic
> static void test(String a, String b, List spreadresult1) {
>     [a, b]*.length()
> }
> test('a', 'b', [])
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)