Eric Milles created GROOVY-10497:
------------------------------------

             Summary: NamedVariant: default value overrides supplied value if 
it's falsy
                 Key: GROOVY-10497
                 URL: https://issues.apache.org/jira/browse/GROOVY-10497
             Project: Groovy
          Issue Type: Bug
            Reporter: Eric Milles


Consider the following:
{code:groovy}
@groovy.transform.NamedVariant
def m(int one, int two = 42) {
    "$one $two"
}
String result = m(one:0, two:0)
assert result == '0 0' // fails
{code}



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

Reply via email to