[Next] Trailing commas in function parameters.
authorgskachkov@gmail.com <gskachkov@gmail.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 28 May 2016 18:26:41 +0000 (18:26 +0000)
committergskachkov@gmail.com <gskachkov@gmail.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 28 May 2016 18:26:41 +0000 (18:26 +0000)
commitabb2d156b9542448cf432aa9a6a99f0616deb77e
tree91caefa4e4ebfe536165420e29af420bf97feb1f
parentaff37ae81820e99b327752d7b4d71fbe6aecea90
[Next] Trailing commas in function parameters.
https://bugs.webkit.org/show_bug.cgi?id=158020

Reviewed by Keith Miller.

ESNext allow to add trailing commas in function parameters and function arguments.
Link to spec - https://jeffmo.github.io/es-trailing-function-commas
Example of using - (function (a, b,) { return a + b; })(1,2,);

* parser/Parser.cpp:
(JSC::Parser<LexerType>::parseFormalParameters):
(JSC::Parser<LexerType>::parseArguments):
* tests/stress/trailing-comma-in-function-paramters.js: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@201488 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/js/parser-syntax-check-expected.txt
LayoutTests/js/script-tests/parser-syntax-check.js
LayoutTests/sputnik/Conformance/13_Function_Definition/S13_A5.html
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/parser/Parser.cpp
Source/JavaScriptCore/tests/stress/trailing-comma-in-function-paramters.js [new file with mode: 0644]