puppetlabs/puppet — pull request #2588 by hlindberg (2014-04-27 00:05:50+00:00)
Title: (PUP-2287) Fix lambda param with default is always choosen

This fixes the problem that a lambda parameter with a default always
was choosen even if a value was given for the parameter.

The expected behavior for function calls is that only truly missing (non
given) arguments are subjects to default value replacement, not if a
value is nil or undef. (This because functions are call by position, and
not call by name as for defines and classes). Thus all nil/undef values
are treated as any other value.

One test for the map function relied on the now fixed bug and it has
been marked pending, as it should be updated once the map function has
been transitioned to the new function API. (Where undef is not
transformed to empty string).