Backed out changeset 805f1a2737a0 (bug 1492074) for causing bug 1503009. a=RyanVM
authorJon Coppeard <jcoppeard@mozilla.com>
Wed, 31 Oct 2018 05:51:00 -0400
changeset 500928 dd2b79631e52ceea81d5b2e46b36901948608e53
parent 500927 c5c1526daf281e50a924bba862a760a9aea363f0
child 500929 c2d642cb5eb28fedc0b8edb46e9fd02d2f689e2b
push id1864
push userffxbld-merge
push dateMon, 03 Dec 2018 15:51:40 +0000
treeherdermozilla-release@f040763d99ad [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersRyanVM
bugs1492074, 1503009
milestone64.0
backs out805f1a2737a0ef58a64cf8e7b6239543d4b45940
Backed out changeset 805f1a2737a0 (bug 1492074) for causing bug 1503009. a=RyanVM
js/src/frontend/Parser.cpp
js/src/jit-test/tests/modules/dynamic-import-lazy.js
testing/web-platform/meta/html/semantics/scripting-1/the-script-element/module/dynamic-import/dynamic-imports-fetch-error.sub.html.ini
testing/web-platform/meta/html/semantics/scripting-1/the-script-element/module/dynamic-import/dynamic-imports-script-error.html.ini
--- a/js/src/frontend/Parser.cpp
+++ b/js/src/frontend/Parser.cpp
@@ -10908,20 +10908,16 @@ GeneralParser<ParseHandler, Unit>::impor
     } else if (next == TokenKind::LeftParen) {
         Node arg = assignExpr(InAllowed, yieldHandling, TripledotProhibited);
         if (!arg) {
             return null();
         }
 
         MUST_MATCH_TOKEN_MOD(TokenKind::RightParen, TokenStream::Operand, JSMSG_PAREN_AFTER_ARGS);
 
-        if (!abortIfSyntaxParser()) {
-            return null();
-        }
-
         return handler.newCallImport(importHolder, arg);
     } else {
         error(JSMSG_UNEXPECTED_TOKEN_NO_EXPECT, TokenKindToDesc(next));
         return null();
     }
 }
 
 template <class ParseHandler, typename Unit>
deleted file mode 100644
--- a/js/src/jit-test/tests/modules/dynamic-import-lazy.js
+++ /dev/null
@@ -1,6 +0,0 @@
-// |jit-test| error: SyntaxError
-
-function lazyilyParsedFunction()
-{
-    return import("/module1.js");
-}
--- a/testing/web-platform/meta/html/semantics/scripting-1/the-script-element/module/dynamic-import/dynamic-imports-fetch-error.sub.html.ini
+++ b/testing/web-platform/meta/html/semantics/scripting-1/the-script-element/module/dynamic-import/dynamic-imports-fetch-error.sub.html.ini
@@ -1,4 +1,9 @@
 [dynamic-imports-fetch-error.sub.html]
+  expected: ERROR
   [import(): error cases occuring during fetching]
     expected: FAIL
+
+  [import() must reject when there is a wrong MIME type]
+    expected: FAIL
+
     bug: 1342012
--- a/testing/web-platform/meta/html/semantics/scripting-1/the-script-element/module/dynamic-import/dynamic-imports-script-error.html.ini
+++ b/testing/web-platform/meta/html/semantics/scripting-1/the-script-element/module/dynamic-import/dynamic-imports-script-error.html.ini
@@ -1,3 +1,8 @@
 [dynamic-imports-script-error.html]
+  expected: ERROR
   [import(): error cases caused by the imported module script]
     expected: FAIL
+
+  [import() must reject when there is a parse error]
+    expected: FAIL
+