You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@groovy.apache.org by "Eric Milles (Jira)" <ji...@apache.org> on 2021/04/27 19:07:00 UTC

[jira] [Resolved] (GROOVY-10062) STC: no type parameter inference for variadic method called with fewer arguments than parameters

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

Eric Milles resolved GROOVY-10062.
----------------------------------
    Fix Version/s: 4.0.0-beta-1
       Resolution: Fixed

> STC: no type parameter inference for variadic method called with fewer arguments than parameters
> ------------------------------------------------------------------------------------------------
>
>                 Key: GROOVY-10062
>                 URL: https://issues.apache.org/jira/browse/GROOVY-10062
>             Project: Groovy
>          Issue Type: Bug
>          Components: Static Type Checker
>            Reporter: Eric Milles
>            Assignee: Eric Milles
>            Priority: Major
>             Fix For: 4.0.0-beta-1
>
>
> Consider the following:
> {code:groovy}
> def <T> T m(T t, ... zeroOrMore) {
> }
> def obj = m(42)
> {code}
> When method "m" is called with just one argument, STC does not infer the type of "T".



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