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

Paul King updated GROOVY-8961:
------------------------------
    Fix Version/s: 2.5.15

> Cannot pass generic list into explicit setter
> ---------------------------------------------
>
>                 Key: GROOVY-8961
>                 URL: https://issues.apache.org/jira/browse/GROOVY-8961
>             Project: Groovy
>          Issue Type: Bug
>          Components: Static Type Checker
>    Affects Versions: 2.5.5
>            Reporter: Daniil Ovchinnikov
>            Assignee: Eric Milles
>            Priority: Major
>             Fix For: 4.0.0-alpha-1, 3.0.6, 2.5.15
>
>          Time Spent: 20m
>  Remaining Estimate: 0h
>
> {code}
> class GC {
>     void setStrings(List<String> ss) {}
> }
> @groovy.transform.CompileStatic
> void usage(GC gc) {
>     gc.strings = Collections.emptyList()
> }
> {code}
> {noformat}
> [Static type checking] - Cannot assign value of type java.util.List <T 
> extends java.lang.Object> to variable of type java.util.List <String>
>  at line: 7, column: 5
> {noformat}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to