Description[es6] enable destructuring rest parameters
Originally, only BindingIdentifiers were a legal operand for the `...` ellipsis
in a function rest parameter. This has since changed, allowing the rest array
to be destructured.
The grammar is now the following:
```
FunctionRestParameter[Yield]:
BindingRestElement[?Yield]
BindingRestElement[Yield]:
... BindingIdentifier[?Yield]
... BindingPattern[?Yield]
```
*Spec change: https://github.com/tc39/ecma262/commit/d322357e6be95bc4bd3e03f5944a736aac55fa50
*TC39 Discussion: https://github.com/tc39/tc39-notes/blob/master/es7/2015-07/july-28.md#66-bindingrestelement-should-allow-a-bindingpattern-ala-assignmentrestelement
BUG=v8:4627, v8:2159
LOG=N
R=littledan@chromium.org, adamk@chromium.org, wingo@igalia.com, rossberg@chromium.org
Committed: https://crrev.com/dfce900d64f2579607705fd2d94c13f28c2e996f
Cr-Commit-Position: refs/heads/master@{#33192}
Patch Set 1 : #Patch Set 2 : Rebase ontop of recent changes to Rest Params #Patch Set 3 : Update test262 expectations #
Messages
Total messages: 19 (5 generated)
|