HomePhorge

(PUP-4398) Fix problem with splatted args in parentheses
365616e6d4e1Unpublished

Unpublished Commit · Learn More

Repository Importing: This repository is still importing.

Description

(PUP-4398) Fix problem with splatted args in parentheses

Before this, if a splat or arguments was placed in parentheses in
a context where an unfold/splat has special meaning it would not be
recognized as a splat.

e.g.

(*[1,2,3]).with |$x, $y, $z| { notice $x, $y, $z }

would give the array to $x, and then fail because $y and $z was not
given.

This was caused by not unwinding parenthesized expressions in positions
where an UnfoldExpression is recognized - i.e. arguments in calls, case
and selector options.

The problem was reported against method call, since there, if splatting
is wanted, it must be in parentheses because of precedence.

This fixes all three places where splatting is recognized as special.

Details

Provenance
Henrik Lindberg <henrik.lindberg@cloudsmith.com>Authored on
vanmeeuwenPushed on Jun 2 2015, 2:22 PM
Parents
rPU89419d85e1ba: Merge pull request #3816 from er0ck/acceptance/3.x/pup…
Branches
Unknown
Tags
Unknown

Event Timeline

Henrik Lindberg <henrik.lindberg@cloudsmith.com> committed rPU365616e6d4e1: (PUP-4398) Fix problem with splatted args in parentheses (authored by Henrik Lindberg <henrik.lindberg@cloudsmith.com>).Apr 15 2015, 11:42 PM