[INTL] Implement Array.prototype.toLocaleString in ECMA-402
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 22 Jan 2016 02:05:28 +0000 (02:05 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 22 Jan 2016 02:05:28 +0000 (02:05 +0000)
commit141a9e06f4540b6e3ee914b0806b1a925e4ee370
tree447b2c6563b47ff748ed404f3ae109a6d2825bde
parente8e852bfec091e99d97cd916de5dd7418a261e6b
[INTL] Implement Array.prototype.toLocaleString in ECMA-402
https://bugs.webkit.org/show_bug.cgi?id=147614

Patch by Andy VanWagoner <andy@instructure.com> on 2016-01-21
Reviewed by Benjamin Poulain.

Source/JavaScriptCore:

The primary changes in the ECMA-402 version, and the existing implementation
are passing the arguments on to each element's toLocaleString call, and
missing/undefined/null elements become empty string instead of being skipped.

* runtime/ArrayPrototype.cpp:
(JSC::arrayProtoFuncToLocaleString):

LayoutTests:

* js/array-toLocaleString-expected.txt: Added.
* js/array-toLocaleString.html: Added.
* js/script-tests/array-toLocaleString.js: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@195431 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/js/array-toLocaleString-expected.txt [new file with mode: 0644]
LayoutTests/js/array-toLocaleString.html [new file with mode: 0644]
LayoutTests/js/script-tests/array-toLocaleString.js [new file with mode: 0644]
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/runtime/ArrayPrototype.cpp