Skip to content
Snippets Groups Projects
Unverified Commit 0ad3d51f authored by Leo Balter's avatar Leo Balter
Browse files

Add an early error case for ({ async async })

parent ca314476
No related branches found
No related tags found
No related merge requests found
// Copyright (C) 2017 Mozilla Corporation. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
description: >
async is not a valid prefix of an identifier reference
esid: sec-object-initializer
info: |
PropertyDefinition:
IdentifierReference
CoverInitializedName
PropertyName : AssignmentExpression
MethodDefinition
MethodDefinition:
PropertyName ( UniqueFormalParameters ) { FunctionBody }
AsyncMethod
AsyncMethod:
async [no LineTerminator here] PropertyName ( UniqueFormalParameters ) { AsyncFunctionBody }
VariableDeclaration : BindingPattern Initializer
1. Let rhs be the result of evaluating Initializer.
2. Let rval be GetValue(rhs).
3. ReturnIfAbrupt(rval).
4. Return the result of performing BindingInitialization for
BindingPattern passing rval and undefined as arguments.
negative:
phase: early
type: SyntaxError
---*/
({async async});
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment