You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@groovy.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2015/11/30 19:39:10 UTC
[jira] [Commented] (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:comment-tabpanel&focusedCommentId=15032227#comment-15032227 ]
ASF GitHub Bot commented on GROOVY-7694:
----------------------------------------
GitHub user shils opened a pull request:
https://github.com/apache/incubator-groovy/pull/200
GROOVY-7694 Results of spread safe method calls should be stored in t…
…emporary variables
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/shils/incubator-groovy GROOVY-7694
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/incubator-groovy/pull/200.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #200
----
commit e8375876967a262cceeda73d108240b2d09e896f
Author: Shil Sinha <sh...@apache.org>
Date: 2015-11-30T18:36:57Z
GROOVY-7694 Results of spread safe method calls should be stored in temporary variables
----
> 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
>
> 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)