array-destructuring-param-strict-body.js |
---
description: ArrayBindingPattern and Use Strict Directive are not allowed to coexist for the same function. (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [rest-parameters]
flags: [generated]
negative:
phase: parse
type: SyntaxError
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
13.3.3.4 Static Semantics: IsSimpleParameterList
BindingElement : BindingPattern
1. Return false.
14.1.2 Static Semantics: Early Errors
FunctionDeclaration : function BindingIdentifier ( FormalParameters ) { FunctionBody }
FunctionDeclaration : function ( FormalParameters ) { FunctionBody }
FunctionExpression : function BindingIdentifier ( FormalParameters ) { FunctionBody }
- It is a Syntax Error if ContainsUseStrict of FunctionBody is true and
IsSimpleParameterList of FormalParameters is false.
14.2.1 Static Semantics: Early Errors
ArrowFunction : ArrowParameters => ConciseBody
- It is a Syntax Error if ContainsUseStrict of ConciseBody is true and
IsSimpleParameterList of ArrowParameters is false.
14.3.1 Static Semantics: Early Errors
MethodDefinition : PropertyName ( UniqueFormalParameters ) { FunctionBody }
- It is a Syntax Error if ContainsUseStrict of FunctionBody is true and
IsSimpleParameterList of UniqueFormalParameters is false.
MethodDefinition : set PropertyName ( PropertySetParameterList ) { FunctionBody }
- It is a Syntax Error if ContainsUseStrict of FunctionBody is true and
IsSimpleParameterList of PropertySetParameterList is false.
14.4.1 Static Semantics: Early Errors
GeneratorMethod : * PropertyName ( UniqueFormalParameters ) { GeneratorBody }
- It is a Syntax Error if ContainsUseStrict of GeneratorBody is true and
IsSimpleParameterList of UniqueFormalParameters is false.
GeneratorDeclaration : function * BindingIdentifier ( FormalParameters ) { GeneratorBody }
GeneratorDeclaration : function * ( FormalParameters ) { GeneratorBody }
GeneratorExpression : function * BindingIdentifier ( FormalParameters ) { GeneratorBody }
- It is a Syntax Error if ContainsUseStrict of GeneratorBody is true and
IsSimpleParameterList of UniqueFormalParameters is false.
14.5.1 Static Semantics: Early Errors
AsyncGeneratorMethod : async * PropertyName ( UniqueFormalParameters ) { AsyncGeneratorBody }
- It is a Syntax Error if ContainsUseStrict of AsyncGeneratorBody is true and
IsSimpleParameterList of UniqueFormalParameters is false.
AsyncGeneratorDeclaration : async function * BindingIdentifier ( FormalParameters ) { AsyncGeneratorBody }
AsyncGeneratorDeclaration : async function * ( FormalParameters ) { AsyncGeneratorBody }
AsyncGeneratorExpression : async function * BindingIdentifier ( FormalParameters ) { AsyncGeneratorBody }
- It is a Syntax Error if ContainsUseStrict of AsyncGeneratorBody is true and
IsSimpleParameterList of FormalParameters is false.
14.7.1 Static Semantics: Early Errors
AsyncMethod : async PropertyName ( UniqueFormalParameters ) { AsyncFunctionBody }
- It is a Syntax Error if ContainsUseStrict of AsyncFunctionBody is true and
IsSimpleParameterList of UniqueFormalParameters is false.
AsyncFunctionDeclaration : async function BindingIdentifier ( FormalParameters ) { AsyncFunctionBody }
AsyncFunctionDeclaration : async function ( FormalParameters ) { AsyncFunctionBody }
AsyncFunctionExpression : async function ( FormalParameters ) { AsyncFunctionBody }
AsyncFunctionExpression : async function BindingIdentifier ( FormalParameters ) { AsyncFunctionBody }
- It is a Syntax Error if ContainsUseStrict of AsyncFunctionBody is true and
IsSimpleParameterList of FormalParameters is false.
14.8.1 Static Semantics: Early Errors
AsyncArrowFunction : CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
- It is a Syntax Error if ContainsUseStrict of AsyncConciseBody is true and
IsSimpleParameterList of CoverCallExpressionAndAsyncArrowHead is false.
--- |
4891 |
arrow-returns-promise.js |
---
author: Brian Terlson <brian.terlson@microsoft.com>
esid: pending
description: >
Async arrow functions return promises
flags: [async]
--- |
464 |
async-lineterminator-identifier-throws.js |
---
esid: prod-AsyncArrowFunction
description: >
async arrows cannot have a line terminator between "async" and the AsyncArrowBindingIdentifier
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction:
async [no LineTerminator here] AsyncArrowBindingIdentifier [no LineTerminator here] => AsyncConciseBody
[...]
--- |
576 |
await-as-binding-identifier-escaped.js |
---
description: await is a reserved keyword within generator function bodies and may not be used as a binding identifier. (Async arrow function)
esid: prod-AsyncArrowFunction
features: [async-functions]
flags: [generated]
negative:
phase: parse
type: SyntaxError
info: |
Async Arrow Function Definitions
AsyncArrowFunction[In, Yield, Await]:
async [no LineTerminator here] AsyncArrowBindingIdentifier[?Yield] [no LineTerminator here] => AsyncConciseBody[?In]
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await] [no LineTerminator here] => AsyncConciseBody[?In]
AsyncConciseBody[In]:
{ AsyncFunctionBody }
BindingIdentifier : Identifier
It is a Syntax Error if this production has a [Await] parameter and
StringValue of Identifier is "await".
--- |
1076 |
await-as-binding-identifier.js |
---
description: await is a reserved keyword within generator function bodies and may not be used as a binding identifier. (Async arrow function)
esid: prod-AsyncArrowFunction
features: [async-functions]
flags: [generated]
negative:
phase: parse
type: SyntaxError
info: |
Async Arrow Function Definitions
AsyncArrowFunction[In, Yield, Await]:
async [no LineTerminator here] AsyncArrowBindingIdentifier[?Yield] [no LineTerminator here] => AsyncConciseBody[?In]
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await] [no LineTerminator here] => AsyncConciseBody[?In]
AsyncConciseBody[In]:
{ AsyncFunctionBody }
BindingIdentifier : Identifier
It is a Syntax Error if this production has a [Await] parameter and
StringValue of Identifier is "await".
--- |
1063 |
await-as-identifier-reference-escaped.js |
---
description: await is a reserved keyword within generator function bodies and may not be used as an identifier reference. (Async arrow function)
esid: prod-AsyncArrowFunction
features: [async-functions]
flags: [generated]
negative:
phase: parse
type: SyntaxError
info: |
Async Arrow Function Definitions
AsyncArrowFunction[In, Yield, Await]:
async [no LineTerminator here] AsyncArrowBindingIdentifier[?Yield] [no LineTerminator here] => AsyncConciseBody[?In]
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await] [no LineTerminator here] => AsyncConciseBody[?In]
AsyncConciseBody[In]:
{ AsyncFunctionBody }
IdentifierReference : Identifier
It is a Syntax Error if this production has a [Await] parameter and
StringValue of Identifier is "await".
--- |
1084 |
await-as-identifier-reference.js |
---
description: await is a reserved keyword within generator function bodies and may not be used as an identifier reference. (Async arrow function)
esid: prod-AsyncArrowFunction
features: [async-functions]
flags: [generated]
negative:
phase: parse
type: SyntaxError
info: |
Async Arrow Function Definitions
AsyncArrowFunction[In, Yield, Await]:
async [no LineTerminator here] AsyncArrowBindingIdentifier[?Yield] [no LineTerminator here] => AsyncConciseBody[?In]
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await] [no LineTerminator here] => AsyncConciseBody[?In]
AsyncConciseBody[In]:
{ AsyncFunctionBody }
IdentifierReference : Identifier
It is a Syntax Error if this production has a [Await] parameter and
StringValue of Identifier is "await".
--- |
1071 |
await-as-label-identifier-escaped.js |
---
description: await is a reserved keyword within generator function bodies and may not be used as a label identifier. (Async arrow function)
esid: prod-AsyncArrowFunction
features: [async-functions]
flags: [generated]
negative:
phase: parse
type: SyntaxError
info: |
Async Arrow Function Definitions
AsyncArrowFunction[In, Yield, Await]:
async [no LineTerminator here] AsyncArrowBindingIdentifier[?Yield] [no LineTerminator here] => AsyncConciseBody[?In]
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await] [no LineTerminator here] => AsyncConciseBody[?In]
AsyncConciseBody[In]:
{ AsyncFunctionBody }
LabelIdentifier : Identifier
It is a Syntax Error if this production has a [Await] parameter and
StringValue of Identifier is "await".
--- |
1068 |
await-as-label-identifier.js |
---
description: await is a reserved keyword within generator function bodies and may not be used as a label identifier. (Async arrow function)
esid: prod-AsyncArrowFunction
features: [async-functions]
flags: [generated]
negative:
phase: parse
type: SyntaxError
info: |
Async Arrow Function Definitions
AsyncArrowFunction[In, Yield, Await]:
async [no LineTerminator here] AsyncArrowBindingIdentifier[?Yield] [no LineTerminator here] => AsyncConciseBody[?In]
CoverCallExpressionAndAsyncArrowHead[?Yield, ?Await] [no LineTerminator here] => AsyncConciseBody[?In]
AsyncConciseBody[In]:
{ AsyncFunctionBody }
LabelIdentifier : Identifier
It is a Syntax Error if this production has a [Await] parameter and
StringValue of Identifier is "await".
--- |
1055 |
await-as-param-ident-nested-arrow-parameter-position.js |
---
esid: sec-async-arrow-function-definitions
description: >
It is a SyntaxError if FormalParameters' default expressions contains await.
negative:
phase: parse
type: SyntaxError
features: [async-functions]
--- |
434 |
await-as-param-nested-arrow-body-position.js |
---
esid: sec-async-arrow-function-definitions
description: >
It is a SyntaxError if FormalParameters' default expressions contains await.
negative:
phase: parse
type: SyntaxError
features: [async-functions]
--- |
442 |
await-as-param-nested-arrow-parameter-position.js |
---
esid: sec-async-arrow-function-definitions
description: >
It is a SyntaxError if FormalParameters' default expressions contains await.
negative:
phase: parse
type: SyntaxError
features: [async-functions]
--- |
436 |
await-as-param-rest-nested-arrow-parameter-position.js |
---
esid: sec-async-arrow-function-definitions
description: >
It is a SyntaxError if FormalParameters' default expressions contains await.
negative:
phase: parse
type: SyntaxError
features: [async-functions]
--- |
439 |
browser.js |
|
0 |
dflt-params-abrupt.js |
---
description: Abrupt completion returned by evaluation of initializer (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [default-parameters, async-functions]
flags: [generated, async]
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
14.1.19 Runtime Semantics: IteratorBindingInitialization
FormalsList : FormalsList , FormalParameter
1. Let status be the result of performing IteratorBindingInitialization for
FormalsList using iteratorRecord and environment as the arguments.
2. ReturnIfAbrupt(status).
3. Return the result of performing IteratorBindingInitialization for
FormalParameter using iteratorRecord and environment as the arguments.
--- |
1802 |
dflt-params-arg-val-not-undefined.js |
---
description: Use of initializer when argument value is not `undefined` (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [default-parameters, async-functions]
flags: [generated, async]
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
14.1.19 Runtime Semantics: IteratorBindingInitialization
FormalsList : FormalsList , FormalParameter
[...]
23. Let iteratorRecord be Record {[[Iterator]]:
CreateListIterator(argumentsList), [[Done]]: false}.
24. If hasDuplicates is true, then
[...]
25. Else,
a. Perform ? IteratorBindingInitialization for formals with
iteratorRecord and env as arguments.
[...]
--- |
2541 |
dflt-params-arg-val-undefined.js |
---
description: Use of initializer when argument value is `undefined` (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [default-parameters, async-functions]
flags: [generated, async]
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
14.1.19 Runtime Semantics: IteratorBindingInitialization
FormalsList : FormalsList , FormalParameter
[...]
23. Let iteratorRecord be Record {[[Iterator]]:
CreateListIterator(argumentsList), [[Done]]: false}.
24. If hasDuplicates is true, then
[...]
25. Else,
a. Perform ? IteratorBindingInitialization for formals with
iteratorRecord and env as arguments.
[...]
--- |
1810 |
dflt-params-duplicates.js |
---
description: It is a Syntax Error if BoundNames of FormalParameters contains any duplicate elements. (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [default-parameters]
flags: [generated]
negative:
phase: parse
type: SyntaxError
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
14.1.2 Static Semantics: Early Errors
StrictFormalParameters : FormalParameters
- It is a Syntax Error if BoundNames of FormalParameters contains any
duplicate elements.
FormalParameters : FormalParameterList
- It is a Syntax Error if IsSimpleParameterList of FormalParameterList is
false and BoundNames of FormalParameterList contains any duplicate
elements.
--- |
1478 |
dflt-params-ref-later.js |
---
description: Referencing a parameter that occurs later in the ParameterList (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [default-parameters, async-functions]
flags: [generated, async]
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
14.1.19 Runtime Semantics: IteratorBindingInitialization
FormalsList : FormalsList , FormalParameter
1. Let status be the result of performing IteratorBindingInitialization for
FormalsList using iteratorRecord and environment as the arguments.
2. ReturnIfAbrupt(status).
3. Return the result of performing IteratorBindingInitialization for
FormalParameter using iteratorRecord and environment as the arguments.
--- |
1785 |
dflt-params-ref-prior.js |
---
description: Referencing a parameter that occurs earlier in the ParameterList (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [default-parameters, async-functions]
flags: [generated, async]
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
14.1.19 Runtime Semantics: IteratorBindingInitialization
FormalsList : FormalsList , FormalParameter
1. Let status be the result of performing IteratorBindingInitialization for
FormalsList using iteratorRecord and environment as the arguments.
2. ReturnIfAbrupt(status).
3. Return the result of performing IteratorBindingInitialization for
FormalParameter using iteratorRecord and environment as the arguments.
--- |
1843 |
dflt-params-ref-self.js |
---
description: Referencing a parameter from within its own initializer (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [default-parameters, async-functions]
flags: [generated, async]
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
14.1.19 Runtime Semantics: IteratorBindingInitialization
FormalsList : FormalsList , FormalParameter
1. Let status be the result of performing IteratorBindingInitialization for
FormalsList using iteratorRecord and environment as the arguments.
2. ReturnIfAbrupt(status).
3. Return the result of performing IteratorBindingInitialization for
FormalParameter using iteratorRecord and environment as the arguments.
--- |
1774 |
dflt-params-rest.js |
---
description: RestParameter does not support an initializer (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [default-parameters]
flags: [generated]
negative:
phase: parse
type: SyntaxError
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
14.1 Function Definitions
Syntax
FunctionRestParameter[Yield] :
BindingRestElement[?Yield]
13.3.3 Destructuring Binding Patterns
Syntax
BindingRestElement[Yield] :
...BindingIdentifier[?Yield]
...BindingPattern[?Yield]
--- |
1297 |
dflt-params-trailing-comma.js |
---
description: A trailing comma should not increase the respective length, using default parameters (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [async-functions]
flags: [generated, async]
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
Trailing comma in the parameters list
14.1 Function Definitions
FormalParameters[Yield, Await] : FormalParameterList[?Yield, ?Await] ,
--- |
1511 |
early-errors-arrow-arguments-in-formal-parameters-strict.js |
---
author: Brian Terlson <brian.terlson@microsoft.com>
esid: pending
description: It is a SyntaxError if FormalParameters contains arguments
negative:
phase: parse
type: SyntaxError
flags: [onlyStrict]
--- |
433 |
early-errors-arrow-await-in-formals-default.js |
---
author: Brian Terlson <brian.terlson@microsoft.com>
esid: pending
description: It is a SyntaxError if FormalParameters' default expressions contains await
negative:
phase: parse
type: SyntaxError
--- |
414 |
early-errors-arrow-await-in-formals.js |
---
author: Brian Terlson <brian.terlson@microsoft.com>
esid: pending
description: It is a SyntaxError if FormalParameters contains await
negative:
phase: parse
type: SyntaxError
--- |
389 |
early-errors-arrow-body-contains-super-call.js |
---
author: Brian Terlson <brian.terlson@microsoft.com>
esid: pending
description: It is a syntax error if AsyncFunctionBody contains SuperCall is true
negative:
phase: parse
type: SyntaxError
--- |
410 |
early-errors-arrow-body-contains-super-property.js |
---
author: Brian Terlson <brian.terlson@microsoft.com>
esid: pending
description: It is a syntax error if AsyncFunctionBody contains SuperProperty is true
negative:
phase: parse
type: SyntaxError
--- |
417 |
early-errors-arrow-duplicate-parameters.js |
---
author: Brian Terlson <brian.terlson@microsoft.com>
esid: sec-async-arrow-function-definitions
description: Formal parameters may not contain duplicates
info: |
# 14.2 Arrow Function Definitions
When the production
ArrowParameters:CoverParenthesizedExpressionAndArrowParameterList
is recognized the following grammar is used to refine the interpretation
of CoverParenthesizedExpressionAndArrowParameterList:
ArrowFormalParameters[Yield, Await]:
(UniqueFormalParameters[?Yield, ?Await])
# 14.1.2 Static Semantics: Early Errors
UniqueFormalParameters:FormalParameters
- It is a Syntax Error if BoundNames of FormalParameters contains any
duplicate elements.
negative:
phase: parse
type: SyntaxError
features: [async-functions]
--- |
977 |
early-errors-arrow-eval-in-formal-parameters-strict.js |
---
author: Brian Terlson <brian.terlson@microsoft.com>
esid: pending
description: It is a SyntaxError if FormalParameters contains eval
negative:
phase: parse
type: SyntaxError
flags: [onlyStrict]
--- |
422 |
early-errors-arrow-formals-body-duplicate.js |
---
author: Brian Terlson <brian.terlson@microsoft.com>
esid: pending
description: It is a SyntaxError if BoundNames of FormalParameters also occurs in the LexicallyDeclaredNames of AsyncFunctionBody
negative:
phase: parse
type: SyntaxError
--- |
458 |
early-errors-arrow-formals-contains-super-call.js |
---
author: Brian Terlson <brian.terlson@microsoft.com>
esid: pending
description: It is a syntax error if FormalParameters contains SuperCall is true
negative:
phase: parse
type: SyntaxError
--- |
409 |
early-errors-arrow-formals-contains-super-property.js |
---
author: Brian Terlson <brian.terlson@microsoft.com>
esid: pending
description: It is a syntax error if FormalParameters contains SuperCall is true
negative:
phase: parse
type: SyntaxError
--- |
413 |
early-errors-arrow-formals-lineterminator.js |
---
esid: prod-AsyncArrowHead
description: async arrows cannot have a line terminator between "async" and the formals
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction:
[...]
CoverCallExpressionAndAsyncArrowHead [no LineTerminator here] => AsyncConciseBody
Supplemental Syntax
When processing an instance of the production
AsyncArrowFunction:
CoverCallExpressionAndAsyncArrowHead [no LineTerminator here] => AsyncConciseBody
the interpretation of CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead:
async [no LineTerminator here] ArrowFormalParameters
negative:
phase: parse
type: SyntaxError
--- |
903 |
early-errors-arrow-NSPL-with-USD.js |
---
author: Brian Terlson <brian.terlson@microsoft.com>
esid: pending
description: >
It is a Syntax Error if ContainsUseStrict of AsyncConciseBody is *true* and IsSimpleParameterList of ArrowParameters is *false*.
negative:
phase: parse
type: SyntaxError
--- |
479 |
escaped-async-line-terminator.js |
---
esid: sec-async-arrow-function-definitions
description: >
Escaped "async" followed by a line-terminator is not misinterpreted as an AsyncArrowFunction.
info: |
14.7 Async Function Definitions
async [no LineTerminator here] AsyncArrowBindingIdentifier[?Yield] [no LineTerminator here] => AsyncConciseBody[?In]
5.1.5 Grammar Notation
Terminal symbols are shown
in fixed width font, both in the productions of the grammars and throughout this
specification whenever the text directly refers to such a terminal symbol. These
are to appear in a script exactly as written. All terminal symbol code points
specified in this way are to be understood as the appropriate Unicode code points
from the Basic Latin range, as opposed to any similar-looking code points from
other Unicode ranges.
features: [async-functions]
--- |
1146 |
escaped-async.js |
---
esid: sec-grammar-notation
description: >
The `async` contextual keyword must not contain Unicode escape sequences.
info: |
Terminal symbols are shown
in fixed width font, both in the productions of the grammars and throughout this
specification whenever the text directly refers to such a terminal symbol. These
are to appear in a script exactly as written. All terminal symbol code points
specified in this way are to be understood as the appropriate Unicode code points
from the Basic Latin range, as opposed to any similar-looking code points from
other Unicode ranges.
negative:
phase: parse
type: SyntaxError
features: [async-functions]
--- |
877 |
eval-var-scope-syntax-err.js |
---
description: sloppy direct eval in params introduces var (async arrow function expression in sloppy code)
esid: sec-async-arrow-function-definitions
features: [default-parameters, async-functions]
flags: [generated, async, noStrict]
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
Runtime Semantics: IteratorBindingInitialization
FormalParameter : BindingElement
1. Return the result of performing IteratorBindingInitialization for BindingElement with arguments iteratorRecord and environment.
--- |
1589 |
forbidden-ext |
|
|
name.js |
---
esid: sec-async-arrow-function-definitions-runtime-semantics-evaluation
description: Assignment of function `name` attribute
info: |
AsyncArrowFunction : async AsyncArrowBindingIdentifier => AsyncConciseBody
1. Let scope be the LexicalEnvironment of the running execution context.
2. Let parameters be AsyncArrowBindingIdentifier.
3. Let closure be ! AsyncFunctionCreate(Arrow, parameters, AsyncConciseBody,
scope, "").
...
5. Return closure.
AsyncArrowFunction : CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
1. Let scope be the LexicalEnvironment of the running execution context.
2. Let head be CoveredAsyncArrowHead of CoverCallExpressionAndAsyncArrowHead.
3. Let parameters be the ArrowFormalParameters of head.
4. Let closure be ! AsyncFunctionCreate(Arrow, parameters, AsyncConciseBody,
scope, "").
...
6. Return closure.
includes: [propertyHelper.js]
--- |
1332 |
object-destructuring-param-strict-body.js |
---
description: ObjectBindingPattern and Use Strict Directive are not allowed to coexist for the same function. (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [rest-parameters]
flags: [generated]
negative:
phase: parse
type: SyntaxError
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
13.3.3.4 Static Semantics: IsSimpleParameterList
BindingElement : BindingPattern
1. Return false.
14.1.2 Static Semantics: Early Errors
FunctionDeclaration : function BindingIdentifier ( FormalParameters ) { FunctionBody }
FunctionDeclaration : function ( FormalParameters ) { FunctionBody }
FunctionExpression : function BindingIdentifier ( FormalParameters ) { FunctionBody }
- It is a Syntax Error if ContainsUseStrict of FunctionBody is true and
IsSimpleParameterList of FormalParameters is false.
14.2.1 Static Semantics: Early Errors
ArrowFunction : ArrowParameters => ConciseBody
- It is a Syntax Error if ContainsUseStrict of ConciseBody is true and
IsSimpleParameterList of ArrowParameters is false.
14.3.1 Static Semantics: Early Errors
MethodDefinition : PropertyName ( UniqueFormalParameters ) { FunctionBody }
- It is a Syntax Error if ContainsUseStrict of FunctionBody is true and
IsSimpleParameterList of UniqueFormalParameters is false.
MethodDefinition : set PropertyName ( PropertySetParameterList ) { FunctionBody }
- It is a Syntax Error if ContainsUseStrict of FunctionBody is true and
IsSimpleParameterList of PropertySetParameterList is false.
14.4.1 Static Semantics: Early Errors
GeneratorMethod : * PropertyName ( UniqueFormalParameters ) { GeneratorBody }
- It is a Syntax Error if ContainsUseStrict of GeneratorBody is true and
IsSimpleParameterList of UniqueFormalParameters is false.
GeneratorDeclaration : function * BindingIdentifier ( FormalParameters ) { GeneratorBody }
GeneratorDeclaration : function * ( FormalParameters ) { GeneratorBody }
GeneratorExpression : function * BindingIdentifier ( FormalParameters ) { GeneratorBody }
- It is a Syntax Error if ContainsUseStrict of GeneratorBody is true and
IsSimpleParameterList of UniqueFormalParameters is false.
14.5.1 Static Semantics: Early Errors
AsyncGeneratorMethod : async * PropertyName ( UniqueFormalParameters ) { AsyncGeneratorBody }
- It is a Syntax Error if ContainsUseStrict of AsyncGeneratorBody is true and
IsSimpleParameterList of UniqueFormalParameters is false.
AsyncGeneratorDeclaration : async function * BindingIdentifier ( FormalParameters ) { AsyncGeneratorBody }
AsyncGeneratorDeclaration : async function * ( FormalParameters ) { AsyncGeneratorBody }
AsyncGeneratorExpression : async function * BindingIdentifier ( FormalParameters ) { AsyncGeneratorBody }
- It is a Syntax Error if ContainsUseStrict of AsyncGeneratorBody is true and
IsSimpleParameterList of FormalParameters is false.
14.7.1 Static Semantics: Early Errors
AsyncMethod : async PropertyName ( UniqueFormalParameters ) { AsyncFunctionBody }
- It is a Syntax Error if ContainsUseStrict of AsyncFunctionBody is true and
IsSimpleParameterList of UniqueFormalParameters is false.
AsyncFunctionDeclaration : async function BindingIdentifier ( FormalParameters ) { AsyncFunctionBody }
AsyncFunctionDeclaration : async function ( FormalParameters ) { AsyncFunctionBody }
AsyncFunctionExpression : async function ( FormalParameters ) { AsyncFunctionBody }
AsyncFunctionExpression : async function BindingIdentifier ( FormalParameters ) { AsyncFunctionBody }
- It is a Syntax Error if ContainsUseStrict of AsyncFunctionBody is true and
IsSimpleParameterList of FormalParameters is false.
14.8.1 Static Semantics: Early Errors
AsyncArrowFunction : CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
- It is a Syntax Error if ContainsUseStrict of AsyncConciseBody is true and
IsSimpleParameterList of CoverCallExpressionAndAsyncArrowHead is false.
--- |
4894 |
params-trailing-comma-multiple.js |
---
description: A trailing comma should not increase the respective length, using multiple parameters (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [async-functions]
flags: [generated, async]
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
Trailing comma in the parameters list
14.1 Function Definitions
FormalParameters[Yield, Await] : FormalParameterList[?Yield, ?Await] ,
--- |
1504 |
params-trailing-comma-single.js |
---
description: A trailing comma should not increase the respective length, using a single parameter (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [async-functions]
flags: [generated, async]
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
Trailing comma in the parameters list
14.1 Function Definitions
FormalParameters[Yield, Await] : FormalParameterList[?Yield, ?Await] ,
--- |
1468 |
prototype.js |
---
esid: sec-async-arrow-function-definitions-runtime-semantics-evaluation
description: The prototype of an async arrow function is %AsyncFunction.prototype%.
info: |
AsyncArrowFunction : async AsyncArrowBindingIdentifier => AsyncConciseBody
...
6. Let closure be OrdinaryFunctionCreate(%AsyncFunction.prototype%, sourceText, parameters,
AsyncConciseBody, lexical-this, env, privateEnv).
...
includes: [hidden-constructors.js]
--- |
692 |
rest-param-strict-body.js |
---
description: RestParameter and Use Strict Directive are not allowed to coexist for the same function. (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [rest-parameters]
flags: [generated]
negative:
phase: parse
type: SyntaxError
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
14.1.13 Static Semantics: IsSimpleParameterList
FormalParameters : FormalParameterList , FunctionRestParameter
1. Return false.
14.1.2 Static Semantics: Early Errors
FunctionDeclaration : function BindingIdentifier ( FormalParameters ) { FunctionBody }
FunctionDeclaration : function ( FormalParameters ) { FunctionBody }
FunctionExpression : function BindingIdentifier ( FormalParameters ) { FunctionBody }
- It is a Syntax Error if ContainsUseStrict of FunctionBody is true and
IsSimpleParameterList of FormalParameters is false.
14.2.1 Static Semantics: Early Errors
ArrowFunction : ArrowParameters => ConciseBody
- It is a Syntax Error if ContainsUseStrict of ConciseBody is true and
IsSimpleParameterList of ArrowParameters is false.
14.3.1 Static Semantics: Early Errors
MethodDefinition : PropertyName ( UniqueFormalParameters ) { FunctionBody }
- It is a Syntax Error if ContainsUseStrict of FunctionBody is true and
IsSimpleParameterList of UniqueFormalParameters is false.
MethodDefinition : set PropertyName ( PropertySetParameterList ) { FunctionBody }
- It is a Syntax Error if ContainsUseStrict of FunctionBody is true and
IsSimpleParameterList of PropertySetParameterList is false.
14.4.1 Static Semantics: Early Errors
GeneratorMethod : * PropertyName ( UniqueFormalParameters ) { GeneratorBody }
- It is a Syntax Error if ContainsUseStrict of GeneratorBody is true and
IsSimpleParameterList of UniqueFormalParameters is false.
GeneratorDeclaration : function * BindingIdentifier ( FormalParameters ) { GeneratorBody }
GeneratorDeclaration : function * ( FormalParameters ) { GeneratorBody }
GeneratorExpression : function * BindingIdentifier ( FormalParameters ) { GeneratorBody }
- It is a Syntax Error if ContainsUseStrict of GeneratorBody is true and
IsSimpleParameterList of UniqueFormalParameters is false.
14.5.1 Static Semantics: Early Errors
AsyncGeneratorMethod : async * PropertyName ( UniqueFormalParameters ) { AsyncGeneratorBody }
- It is a Syntax Error if ContainsUseStrict of AsyncGeneratorBody is true and
IsSimpleParameterList of UniqueFormalParameters is false.
AsyncGeneratorDeclaration : async function * BindingIdentifier ( FormalParameters ) { AsyncGeneratorBody }
AsyncGeneratorDeclaration : async function * ( FormalParameters ) { AsyncGeneratorBody }
AsyncGeneratorExpression : async function * BindingIdentifier ( FormalParameters ) { AsyncGeneratorBody }
- It is a Syntax Error if ContainsUseStrict of AsyncGeneratorBody is true and
IsSimpleParameterList of FormalParameters is false.
14.7.1 Static Semantics: Early Errors
AsyncMethod : async PropertyName ( UniqueFormalParameters ) { AsyncFunctionBody }
- It is a Syntax Error if ContainsUseStrict of AsyncFunctionBody is true and
IsSimpleParameterList of UniqueFormalParameters is false.
AsyncFunctionDeclaration : async function BindingIdentifier ( FormalParameters ) { AsyncFunctionBody }
AsyncFunctionDeclaration : async function ( FormalParameters ) { AsyncFunctionBody }
AsyncFunctionExpression : async function ( FormalParameters ) { AsyncFunctionBody }
AsyncFunctionExpression : async function BindingIdentifier ( FormalParameters ) { AsyncFunctionBody }
- It is a Syntax Error if ContainsUseStrict of AsyncFunctionBody is true and
IsSimpleParameterList of FormalParameters is false.
14.8.1 Static Semantics: Early Errors
AsyncArrowFunction : CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
- It is a Syntax Error if ContainsUseStrict of AsyncConciseBody is true and
IsSimpleParameterList of CoverCallExpressionAndAsyncArrowHead is false.
--- |
4900 |
rest-params-trailing-comma-early-error.js |
---
description: It's a syntax error if a FunctionRestParameter is followed by a trailing comma (async arrow function expression)
esid: sec-async-arrow-function-definitions
flags: [generated]
negative:
phase: parse
type: SyntaxError
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
Trailing comma in the parameters list
14.1 Function Definitions
FormalParameters[Yield, Await] :
[empty]
FunctionRestParameter[?Yield, ?Await]
FormalParameterList[?Yield, ?Await]
FormalParameterList[?Yield, ?Await] ,
FormalParameterList[?Yield, ?Await] , FunctionRestParameter[?Yield, ?Await]
--- |
1395 |
shell.js |
---
description: |
Provides uniform access to built-in constructors that are not exposed to the global object.
defines:
- AsyncFunction
- AsyncGeneratorFunction
- GeneratorFunction
--- |
842 |
try-reject-finally-reject.js |
---
author: Caitlin Potter <caitp@igalia.com>
esid: pending
description: >
Implementations must defer rejecting an async function's Promise until after
all finally blocks have been evaluated.
flags: [async]
--- |
723 |
try-reject-finally-return.js |
---
author: Caitlin Potter <caitp@igalia.com>
esid: pending
description: >
Implementations must defer rejecting an async function's Promise until after
all finally blocks have been evaluated.
flags: [async]
--- |
644 |
try-reject-finally-throw.js |
---
author: Caitlin Potter <caitp@igalia.com>
esid: pending
description: >
Implementations must defer rejecting an async function's Promise until after
all finally blocks have been evaluated.
flags: [async]
--- |
660 |
try-return-finally-reject.js |
---
author: Caitlin Potter <caitp@igalia.com>
esid: pending
description: >
Implementations must defer resolving an async function's Promise until after
all finally blocks have been evaluated.
flags: [async]
--- |
662 |
try-return-finally-return.js |
---
author: Caitlin Potter <caitp@igalia.com>
esid: pending
description: >
Implementations must defer resolving an async function's Promise until after
all finally blocks have been evaluated.
flags: [async]
--- |
652 |
try-return-finally-throw.js |
---
author: Caitlin Potter <caitp@igalia.com>
esid: pending
description: >
Implementations must defer resolving an async function's Promise until after
all finally blocks have been evaluated.
flags: [async]
--- |
599 |
try-throw-finally-reject.js |
---
author: Caitlin Potter <caitp@igalia.com>
esid: pending
description: >
Implementations must defer rejecting an async function's Promise until after
all finally blocks have been evaluated.
flags: [async]
--- |
660 |
try-throw-finally-return.js |
---
author: Caitlin Potter <caitp@igalia.com>
esid: pending
description: >
Implementations must defer rejecting an async function's Promise until after
all finally blocks have been evaluated.
flags: [async]
--- |
650 |
try-throw-finally-throw.js |
---
author: Caitlin Potter <caitp@igalia.com>
esid: pending
description: >
Implementations must defer rejecting an async function's Promise until after
all finally blocks have been evaluated.
flags: [async]
--- |
597 |
unscopables-with-in-nested-fn.js |
---
description: Symbol.unscopables behavior across scope boundaries (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [globalThis, Symbol.unscopables, async-functions]
flags: [generated, noStrict, async]
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
...
Let envRec be lex's EnvironmentRecord.
Let exists be ? envRec.HasBinding(name).
HasBinding
...
If the withEnvironment flag of envRec is false, return true.
Let unscopables be ? Get(bindings, @@unscopables).
If Type(unscopables) is Object, then
Let blocked be ToBoolean(? Get(unscopables, N)).
If blocked is true, return false.
(The `with` Statement) Runtime Semantics: Evaluation
...
Set the withEnvironment flag of newEnv’s EnvironmentRecord to true.
...
--- |
2481 |
unscopables-with.js |
---
description: Symbol.unscopables behavior across scope boundaries (async arrow function expression)
esid: sec-async-arrow-function-definitions
features: [globalThis, Symbol.unscopables, async-functions]
flags: [generated, noStrict, async]
info: |
14.7 Async Arrow Function Definitions
AsyncArrowFunction :
...
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody
AsyncConciseBody :
{ AsyncFunctionBody }
...
Supplemental Syntax
When processing an instance of the production AsyncArrowFunction :
CoverCallExpressionAndAsyncArrowHead => AsyncConciseBody the interpretation of
CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:
AsyncArrowHead :
async ArrowFormalParameters
...
Let envRec be lex's EnvironmentRecord.
Let exists be ? envRec.HasBinding(name).
HasBinding
...
If the withEnvironment flag of envRec is false, return true.
Let unscopables be ? Get(bindings, @@unscopables).
If Type(unscopables) is Object, then
Let blocked be ToBoolean(? Get(unscopables, N)).
If blocked is true, return false.
(The `with` Statement) Runtime Semantics: Evaluation
...
Set the withEnvironment flag of newEnv’s EnvironmentRecord to true.
...
--- |
2306 |