Proposal: rest operator in middle of array

Andy Earnshaw andyearnshaw at gmail.com
Tue Jun 11 08:06:04 UTC 2019


On Mon, 10 Jun 2019 at 22:20, Ethan Resnick <ethan.resnick at gmail.com> wrote:

> @Andy Perhaps you can provide some links? I found two
> <https://esdiscuss.org/topic/an-array-destructing-specification-choice#content-69>
> threads <https://esdiscuss.org/topic/early-spread-operator> — both 8
> years old — that talked about this, along with one more recent one
> <https://esdiscuss.org/topic/strawman-complete-array-and-object-destructuring>
> that didn't get very far. In the first two threads, commenters brought up
> one case where the semantics are unclear (i.e., when there are more listed
> binding elements than there are elements in the iterable), and there was
> some talk about implementation complexity. But there was also some interest
> from some big contributors to the spec. So I wonder if it's time to revisit
> this?
>

Here's the one that I was involved in:

https://esdiscuss.org/topic/rest-parameters

My comment was not meant to be dismissive, I was just hoping to provide
some context (and I was on my mobile at the time). If several discussions
have tailed off over the years without anyone making a concrete proposal,
then it seems unlikely that this discussion will make any more progress
than the ones before it. I think the real limiting factor is that this is
not a burning issue for anyone, not a particular pain point in day to day
programming, so there's no big appetite to try and overcome the main
objections.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20190611/0e92c2a9/attachment.html>


More information about the es-discuss mailing list