Summary: | Implement Annex B.3.3 function hoisting rules for global scope and eval | ||
---|---|---|---|
Product: | WebKit | Reporter: | Saam Barati <saam> |
Component: | JavaScriptCore | Assignee: | Alexey Shvayka <ashvayka> |
Status: | RESOLVED DUPLICATE | ||
Severity: | Normal | CC: | benjamin, buildbot, commit-queue, fpizlo, ggaren, gskachkov, keith_miller, mark.lam, msaboff, oliver, rniwa, ross.kirsling, sukolsak, webkit-bug-importer, ysuzuki |
Priority: | P2 | Keywords: | InRadar |
Version: | WebKit Nightly Build | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Bug Depends on: | 163208 | ||
Bug Blocks: | |||
Attachments: |
Description
Saam Barati
2016-03-23 15:35:40 PDT
I'll start work on this task. I think it should cover https://bugs.webkit.org/show_bug.cgi?id=161099 also Created attachment 290646 [details]
Patch
Some intermediate result
Comment on attachment 290646 [details] Patch Attachment 290646 [details] did not pass mac-ews (mac): Output: http://webkit-queues.webkit.org/results/2220036 New failing tests: js/parser-syntax-check.html js/mozilla/strict/eval-variable-environment.html Created attachment 290654 [details]
Archive of layout-test-results from ews102 for mac-yosemite
The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews102 Port: mac-yosemite Platform: Mac OS X 10.10.5
Comment on attachment 290646 [details] Patch Attachment 290646 [details] did not pass mac-wk2-ews (mac-wk2): Output: http://webkit-queues.webkit.org/results/2220093 New failing tests: js/parser-syntax-check.html js/mozilla/strict/eval-variable-environment.html Created attachment 290656 [details]
Archive of layout-test-results from ews104 for mac-yosemite-wk2
The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews104 Port: mac-yosemite-wk2 Platform: Mac OS X 10.10.5
Comment on attachment 290646 [details] Patch Attachment 290646 [details] did not pass ios-sim-ews (ios-simulator-wk2): Output: http://webkit-queues.webkit.org/results/2220099 New failing tests: js/parser-syntax-check.html js/mozilla/strict/eval-variable-environment.html Created attachment 290657 [details]
Archive of layout-test-results from ews121 for ios-simulator-elcapitan-wk2
The attached test failures were seen while running run-webkit-tests on the ios-sim-ews.
Bot: ews121 Port: ios-simulator-elcapitan-wk2 Platform: Mac OS X 10.11.6
Comment on attachment 290646 [details] Patch Attachment 290646 [details] did not pass mac-debug-ews (mac): Output: http://webkit-queues.webkit.org/results/2220193 New failing tests: js/mozilla/eval/exhaustive-fun-normalcaller-indirect-normalcode.html js/parser-syntax-check.html js/mozilla/eval/exhaustive-fun-strictcaller-direct-strictcode.html js/mozilla/eval/exhaustive-fun-normalcaller-indirect-strictcode.html js/mozilla/eval/exhaustive-fun-strictcaller-indirect-normalcode.html js/mozilla/strict/eval-variable-environment.html js/mozilla/eval/exhaustive-global-normalcaller-indirect-strictcode.html js/mozilla/eval/exhaustive-global-strictcaller-indirect-normalcode.html js/mozilla/eval/exhaustive-global-normalcaller-direct-strictcode.html js/mozilla/eval/exhaustive-global-strictcaller-direct-strictcode.html js/mozilla/eval/exhaustive-global-strictcaller-direct-normalcode.html js/mozilla/eval/exhaustive-fun-strictcaller-direct-normalcode.html js/mozilla/eval/exhaustive-fun-strictcaller-indirect-strictcode.html js/mozilla/eval/exhaustive-global-normalcaller-indirect-normalcode.html js/mozilla/eval/exhaustive-fun-normalcaller-direct-strictcode.html js/mozilla/eval/exhaustive-global-strictcaller-indirect-strictcode.html Created attachment 290661 [details]
Archive of layout-test-results from ews114 for mac-yosemite
The attached test failures were seen while running run-webkit-tests on the mac-debug-ews.
Bot: ews114 Port: mac-yosemite Platform: Mac OS X 10.10.5
Created attachment 290975 [details]
Patch
New PoC of the solution
Attachment 290975 [details] did not pass style-queue:
ERROR: Source/JavaScriptCore/jit/JITPropertyAccess32_64.cpp:733: When wrapping a line, only indent 4 spaces. [whitespace/indent] [3]
ERROR: Source/JavaScriptCore/runtime/JSScope.cpp:243: When wrapping a line, only indent 4 spaces. [whitespace/indent] [3]
ERROR: Source/JavaScriptCore/runtime/JSScope.cpp:244: One line control clauses should not use braces. [whitespace/braces] [4]
ERROR: Source/JavaScriptCore/runtime/CommonSlowPaths.cpp:819: One line control clauses should not use braces. [whitespace/braces] [4]
ERROR: JSTests/stress/foo_func_decl_in_eval_within_block_with_let.js:2: Line contains tab character. [whitespace/tab] [5]
ERROR: JSTests/stress/foo_func_decl_in_eval_within_block_with_let.js:3: Line contains tab character. [whitespace/tab] [5]
ERROR: JSTests/stress/foo_func_decl_in_eval_within_block_with_let.js:4: Line contains tab character. [whitespace/tab] [5]
ERROR: Source/JavaScriptCore/dfg/DFGByteCodeParser.cpp:4842: When wrapping a line, only indent 4 spaces. [whitespace/indent] [3]
Total errors found: 8 in 29 files
If any of these errors are false positives, please file a bug against check-webkit-style.
Comment on attachment 290975 [details]
Patch
No need for review
Comment on attachment 290975 [details] Patch Attachment 290975 [details] did not pass mac-ews (mac): Output: http://webkit-queues.webkit.org/results/2240737 New failing tests: js/parser-syntax-check.html js/mozilla/strict/eval-variable-environment.html Created attachment 290992 [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
Comment on attachment 290975 [details] Patch Attachment 290975 [details] did not pass mac-wk2-ews (mac-wk2): Output: http://webkit-queues.webkit.org/results/2240735 New failing tests: js/parser-syntax-check.html js/mozilla/strict/eval-variable-environment.html Created attachment 290993 [details]
Archive of layout-test-results from ews104 for mac-yosemite-wk2
The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews104 Port: mac-yosemite-wk2 Platform: Mac OS X 10.10.5
Comment on attachment 290975 [details] Patch Attachment 290975 [details] did not pass ios-sim-ews (ios-simulator-wk2): Output: http://webkit-queues.webkit.org/results/2240766 New failing tests: js/parser-syntax-check.html js/mozilla/strict/eval-variable-environment.html Created attachment 290998 [details]
Archive of layout-test-results from ews122 for ios-simulator-wk2
The attached test failures were seen while running run-webkit-tests on the ios-sim-ews.
Bot: ews122 Port: ios-simulator-wk2 Platform: Mac OS X 10.11.6
Comment on attachment 290975 [details] Patch Attachment 290975 [details] did not pass mac-debug-ews (mac): Output: http://webkit-queues.webkit.org/results/2240767 New failing tests: js/mozilla/eval/exhaustive-fun-normalcaller-indirect-normalcode.html js/parser-syntax-check.html js/mozilla/eval/exhaustive-fun-strictcaller-direct-strictcode.html js/mozilla/eval/exhaustive-fun-normalcaller-indirect-strictcode.html js/mozilla/eval/exhaustive-fun-strictcaller-indirect-normalcode.html js/mozilla/strict/eval-variable-environment.html js/mozilla/eval/exhaustive-global-normalcaller-indirect-strictcode.html js/mozilla/eval/exhaustive-global-strictcaller-indirect-normalcode.html js/mozilla/eval/exhaustive-global-normalcaller-direct-strictcode.html js/mozilla/eval/exhaustive-global-strictcaller-direct-strictcode.html js/mozilla/eval/exhaustive-global-strictcaller-direct-normalcode.html js/mozilla/eval/exhaustive-fun-strictcaller-direct-normalcode.html js/mozilla/eval/exhaustive-fun-strictcaller-indirect-strictcode.html js/mozilla/eval/exhaustive-global-normalcaller-indirect-normalcode.html js/mozilla/eval/exhaustive-fun-normalcaller-direct-strictcode.html js/mozilla/eval/exhaustive-global-strictcaller-indirect-strictcode.html Created attachment 291002 [details]
Archive of layout-test-results from ews117 for mac-yosemite
The attached test failures were seen while running run-webkit-tests on the mac-debug-ews.
Bot: ews117 Port: mac-yosemite Platform: Mac OS X 10.10.5
Comment on attachment 290975 [details] Patch Attachment 290975 [details] did not pass mac-debug-ews (mac): Output: http://webkit-queues.webkit.org/results/2241324 New failing tests: js/mozilla/eval/exhaustive-fun-normalcaller-indirect-normalcode.html js/parser-syntax-check.html js/mozilla/strict/eval-variable-environment.html js/mozilla/eval/exhaustive-global-strictcaller-direct-normalcode.html js/mozilla/eval/exhaustive-fun-strictcaller-indirect-normalcode.html js/mozilla/eval/exhaustive-fun-strictcaller-direct-strictcode.html js/mozilla/eval/exhaustive-global-normalcaller-indirect-strictcode.html js/mozilla/eval/exhaustive-fun-normalcaller-direct-strictcode.html js/mozilla/eval/exhaustive-global-strictcaller-indirect-strictcode.html js/mozilla/eval/exhaustive-global-normalcaller-direct-strictcode.html js/mozilla/eval/exhaustive-global-strictcaller-direct-strictcode.html js/mozilla/eval/exhaustive-fun-normalcaller-indirect-strictcode.html js/mozilla/eval/exhaustive-fun-strictcaller-direct-normalcode.html js/mozilla/eval/exhaustive-fun-strictcaller-indirect-strictcode.html js/mozilla/eval/exhaustive-global-normalcaller-indirect-normalcode.html js/mozilla/eval/exhaustive-global-strictcaller-indirect-normalcode.html js/dom/line-column-numbers.html Created attachment 291008 [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
sorry for the noise, this is actually a separate bug Hoisting rules for eval() were implemented long time ago, for global only recently: https://commits.webkit.org/268553@main. *** This bug has been marked as a duplicate of bug 163209 *** |