Bug 155203

Summary: FunctionExecutable::ecmaName() should not be based on inferredName().
Product: WebKit Reporter: Mark Lam <mark.lam>
Component: JavaScriptCoreAssignee: Mark Lam <mark.lam>
Status: RESOLVED FIXED    
Severity: Normal CC: benjamin, buildbot, commit-queue, fpizlo, ggaren, keith_miller, msaboff, rniwa, saam, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Local Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
proposed patch.
buildbot: commit-queue-
Archive of layout-test-results from ews103 for mac-yosemite
none
Archive of layout-test-results from ews106 for mac-yosemite-wk2
none
Archive of layout-test-results from ews112 for mac-yosemite
none
proposed patch: with rebased test result. msaboff: review+

Mark Lam
Reported 2016-03-08 15:36:33 PST
Currently, we're approximating ecmaName()'s behavior using the debugging inferredName of executables. Will fix.
Attachments
proposed patch. (12.33 KB, patch)
2016-03-08 22:37 PST, Mark Lam
buildbot: commit-queue-
Archive of layout-test-results from ews103 for mac-yosemite (762.94 KB, application/zip)
2016-03-08 23:31 PST, Build Bot
no flags
Archive of layout-test-results from ews106 for mac-yosemite-wk2 (807.10 KB, application/zip)
2016-03-08 23:36 PST, Build Bot
no flags
Archive of layout-test-results from ews112 for mac-yosemite (1.77 MB, application/zip)
2016-03-09 00:25 PST, Build Bot
no flags
proposed patch: with rebased test result. (13.38 KB, patch)
2016-03-09 10:18 PST, Mark Lam
msaboff: review+
Mark Lam
Comment 1 2016-03-08 22:19:37 PST
The
Radar WebKit Bug Importer
Comment 2 2016-03-08 22:19:54 PST
Mark Lam
Comment 3 2016-03-08 22:24:26 PST
The ES6 rules for how a function name should be inferred closely matches JSC's implementation with one exception: var o = {} o.foo = function() {} JSC's inferredName for o.foo would be "foo". ES6 specifies that o.foo.name is "". The fix is to add a distinct FunctionExecutable::ecmaName() which applies the ES6 rules for inferring the initial value of Function.name.
Mark Lam
Comment 4 2016-03-08 22:37:29 PST
Created attachment 273394 [details] proposed patch.
Build Bot
Comment 5 2016-03-08 23:31:10 PST
Comment on attachment 273394 [details] proposed patch. Attachment 273394 [details] did not pass mac-ews (mac): Output: http://webkit-queues.webkit.org/results/945691 New failing tests: http/tests/media/media-source/mediasource-sourcebuffer-mode.html
Build Bot
Comment 6 2016-03-08 23:31:13 PST
Created attachment 273401 [details] Archive of layout-test-results from ews103 for mac-yosemite The attached test failures were seen while running run-webkit-tests on the mac-ews. Bot: ews103 Port: mac-yosemite Platform: Mac OS X 10.10.5
Build Bot
Comment 7 2016-03-08 23:36:05 PST
Comment on attachment 273394 [details] proposed patch. Attachment 273394 [details] did not pass mac-wk2-ews (mac-wk2): Output: http://webkit-queues.webkit.org/results/945706 New failing tests: http/tests/media/media-source/mediasource-sourcebuffer-mode.html
Build Bot
Comment 8 2016-03-08 23:36:08 PST
Created attachment 273403 [details] Archive of layout-test-results from ews106 for mac-yosemite-wk2 The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews. Bot: ews106 Port: mac-yosemite-wk2 Platform: Mac OS X 10.10.5
Build Bot
Comment 9 2016-03-09 00:25:24 PST
Comment on attachment 273394 [details] proposed patch. Attachment 273394 [details] did not pass mac-debug-ews (mac): Output: http://webkit-queues.webkit.org/results/945783 New failing tests: http/tests/media/media-source/mediasource-sourcebuffer-mode.html
Build Bot
Comment 10 2016-03-09 00:25:29 PST
Created attachment 273405 [details] Archive of layout-test-results from ews112 for mac-yosemite The attached test failures were seen while running run-webkit-tests on the mac-debug-ews. Bot: ews112 Port: mac-yosemite Platform: Mac OS X 10.10.5
Mark Lam
Comment 11 2016-03-09 09:18:20 PST
Comment on attachment 273394 [details] proposed patch. Taking off review while I investigate test failures.
Mark Lam
Comment 12 2016-03-09 10:18:43 PST
Created attachment 273441 [details] proposed patch: with rebased test result.
WebKit Commit Bot
Comment 13 2016-03-09 10:21:03 PST
Attachment 273441 [details] did not pass style-queue: ERROR: LayoutTests/ChangeLog:10: Need whitespace between colon and description [changelog/filechangedescriptionwhitespace] [5] Total errors found: 1 in 11 files If any of these errors are false positives, please file a bug against check-webkit-style.
Michael Saboff
Comment 14 2016-03-09 11:15:55 PST
Comment on attachment 273441 [details] proposed patch: with rebased test result. r=me. Add a comment in the place where you don't call setEcmaName() to comply with the standard.
Mark Lam
Comment 15 2016-03-09 11:37:09 PST
Thanks for the review. Added requested comment and landed in r197867: <http://trac.webkit.org/197867>.
Note You need to log in before you can comment on or make changes to this bug.