Closed Bug 1361143 Opened 4 years ago Closed 4 years ago

Missing expression statement restriction for "async function"

Categories

(Core :: JavaScript Engine, enhancement)

enhancement
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla55
Tracking Status
firefox55 --- fixed

People

(Reporter: anba, Assigned: anba)

Details

Attachments

(1 file)

No description provided.
Created test262 PR for tests at https://github.com/tc39/test262/pull/1017
Attached patch bug1361143.patchSplinter Review
We only needed to move the syntax check from Parser::consequentOrAlternative() to Parser::statement(). And while I was there, I've also removed the check for "let" in strict or js1.7 mode, because strict-mode is also handled in Parser::checkLabelOrIdentifierReference() and if we care about js1.7 error messages, the js1.7 version check should also be moved Parser::checkLabelOrIdentifierReference().
Attachment #8863879 - Flags: review?(shu)
Attachment #8863879 - Flags: review?(shu) → review+
Pushed by ryanvm@gmail.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/61ea278ec204
Enforce lookahead restriction for "async function" in expression statements. r=shu
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/61ea278ec204
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla55
You need to log in before you can comment on or make changes to this bug.