spread operator (...) as a new token

Kang-Hao (Kenny) Lu kanghaol at oupeng.com
Thu Jan 17 18:51:56 PST 2013

Is "..." a new token that should be listed in Punctuator. I think it
should and it seems like a little miss for which I am happy to file a
bug, but I am not so sure as the proposal[1] doesn't include it.

It seems that Firefox implements it as a token. Test cases:

  function x(. ..y) {}

  function x(./**/..y) {}

. Both throw SyntaxError in Firefox 17.

[1] http://wiki.ecmascript.org/doku.php?id=harmony:spread#syntax

Web Specialist, Oupeng Browser, Beijing
Try Oupeng: http://www.oupeng.com/

More information about the es-discuss mailing list