Source/JavaScriptCore:
authorsbarati@apple.com <sbarati@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 7 Feb 2016 23:16:20 +0000 (23:16 +0000)
committersbarati@apple.com <sbarati@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 7 Feb 2016 23:16:20 +0000 (23:16 +0000)
commitb86a6145d34eb758c55099f758059bc6ea3e0eaf
tree15aca5e23fa90cc19444304210beb374223528c3
parentf63e036a13242c4b076d9446dc1d6e9634aa9ebc
Source/JavaScriptCore:
Follow up patch to: [ES6] bound functions .name property should be "bound " + the target function's name
https://bugs.webkit.org/show_bug.cgi?id=153796

Reviewed by Darin Adler.

This follow-up patch addresses some comments/suggestions by
Ryosuke, Darin, and Joe. It simplifies JSBoundFunction::toStringName
and adds some tests for bound names.

* runtime/JSBoundFunction.cpp:
(JSC::hasInstanceBoundFunction):
(JSC::JSBoundFunction::create):
(JSC::JSBoundFunction::toStringName):

LayoutTests:
[ES6] bound functions .name property should be "bound " + the target function's name
https://bugs.webkit.org/show_bug.cgi?id=153796

Reviewed by Darin Adler.

* js/bound-function-name-expected.txt: Added.
* js/bound-function-name.html: Added.
* js/script-tests/bound-function-name.js: Added.
(assert):
(assert.foo):
(bar):

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