Changeset 266318 in webkit for trunk/Source/JavaScriptCore
- Timestamp:
- Aug 28, 2020, 7:26:40 PM (5 years ago)
- Location:
- trunk/Source/JavaScriptCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r266264 r266318 1 2020-08-28 Yusuke Suzuki <[email protected]> 2 3 [JSC] `new import.meta()` is acceptable 4 https://bugs.webkit.org/show_bug.cgi?id=215915 5 6 Reviewed by Ross Kirsling. 7 8 `new import.meta()` is valid in terms of syntax while it throws runtime error. 9 We should accept this code, while `new import()` is not correct syntax. 10 11 * parser/Parser.cpp: 12 (JSC::Parser<LexerType>::parseMemberExpression): 13 1 14 2020-08-27 Alexey Shvayka <[email protected]> 2 15 -
trunk/Source/JavaScriptCore/parser/Parser.cpp
r266264 r266318 4844 4844 bool previousBaseWasSuper = false; 4845 4845 bool baseIsImport = match(IMPORT); 4846 semanticFailIfTrue( (baseIsSuper || baseIsImport)&& newCount, "Cannot use new with ", getToken());4846 semanticFailIfTrue(baseIsSuper && newCount, "Cannot use new with ", getToken()); 4847 4847 4848 4848 bool baseIsNewTarget = false; … … 4904 4904 } 4905 4905 } else { 4906 semanticFailIfTrue(newCount, "Cannot use new with import"); 4906 4907 consumeOrFail(OPENPAREN, "import call expects exactly one argument"); 4907 4908 TreeExpression expr = parseAssignmentExpression(context);
Note:
See TracChangeset
for help on using the changeset viewer.