Generated using http://github.com/rbuckton/grammarkdown
SourceCharacter ::
any Unicode code point
InputElementDiv ::
WhiteSpace
LineTerminator
Comment
CommonToken
DivPunctuator
RightBracePunctuator
InputElementRegExp ::
WhiteSpace
LineTerminator
Comment
CommonToken
RightBracePunctuator
RegularExpressionLiteral
InputElementRegExpOrTemplateTail ::
WhiteSpace
LineTerminator
Comment
CommonToken
RegularExpressionLiteral
TemplateSubstitutionTail
InputElementTemplateTail ::
WhiteSpace
LineTerminator
Comment
CommonToken
DivPunctuator
TemplateSubstitutionTail
WhiteSpace ::
<TAB>
<VT>
<FF>
<SP>
<NBSP>
<ZWNBSP>
<USP>
LineTerminator ::
<LF>
<CR>
<LS>
<PS>
LineTerminatorSequence ::
<LF>
<CR> [lookahead ≠ <LF>]
<LS>
<PS>
<CR> <LF>
Comment ::
MultiLineComment
SingleLineComment
MultiLineComment ::
/*
MultiLineCommentCharsopt */
MultiLineCommentChars ::
MultiLineNotAsteriskChar MultiLineCommentCharsopt
*
PostAsteriskCommentCharsopt
PostAsteriskCommentChars ::
MultiLineNotForwardSlashOrAsteriskChar MultiLineCommentCharsopt
*
PostAsteriskCommentCharsopt
MultiLineNotAsteriskChar ::
SourceCharacter but not *
MultiLineNotForwardSlashOrAsteriskChar ::
SourceCharacter but not one of /
or *
SingleLineComment ::
//
SingleLineCommentCharsopt
SingleLineCommentChars ::
SingleLineCommentChar SingleLineCommentCharsopt
SingleLineCommentChar ::
SourceCharacter but not LineTerminator
CommonToken ::
IdentifierName
Punctuator
NumericLiteral
StringLiteral
Template
IdentifierName ::
IdentifierStart
IdentifierName IdentifierPart
IdentifierStart ::
UnicodeIDStart
$
_
\
UnicodeEscapeSequence
IdentifierPart ::
UnicodeIDContinue
$
_
\
UnicodeEscapeSequence
<ZWNJ>
<ZWJ>
UnicodeIDStart ::
any Unicode code point with the Unicode property "ID_Start" or "Other_ID_Start"
UnicodeIDContinue ::
any Unicode code point with the Unicode property "ID_Continue" or "Other_ID_Continue", or "Other_ID_Start"
ReservedWord ::
Keyword
FutureReservedWord
NullLiteral
BooleanLiteral
break
do
in
typeof
case
else
instanceof
var
catch
export
new
void
class
extends
return
while
const
finally
super
with
continue
for
switch
yield
debugger
function
this
default
if
throw
delete
import
try
enum
await
implements
package
protected
interface
private
public
{
}
(
)
[
]
.
;
,
<
>
<=
>=
==
!=
===
!==
+
-
*
%
++
--
<<
>>
>>>
&
|
^
!
~
&&
||
?
::
=
+=
-=
*=
%=
<<=
>>=
>>>=
&=
|=
^=
=>
/
/=
RightBracePunctuator :: one of
)
NumericLiteral ::
DecimalLiteral
BinaryIntegerLiteral
OctalIntegerLiteral
HexIntegerLiteral
DecimalLiteral ::
DecimalIntegerLiteral .
DecimalDigitsopt ExponentPartopt
.
DecimalDigits ExponentPartopt
DecimalIntegerLiteral ExponentPartopt
DecimalIntegerLiteral ::
0
NonZeroDigit DecimalDigitsopt
DecimalDigits ::
DecimalDigit
DecimalDigits DecimalDigit
0
1
2
3
4
5
6
7
8
9
1
2
3
4
5
6
7
8
9
ExponentPart ::
ExponentIndicator SignedInteger
e
E
SignedInteger ::
DecimalDigits
+
DecimalDigits
-
DecimalDigits
BinaryIntegerLiteral ::
0b
BinaryDigits
0B
BinaryDigits
BinaryDigits ::
BinaryDigit
BinaryDigits BinaryDigit
0
1
OctalIntegerLiteral ::
0o
OctalDigits
0O
OctalDigits
OctalDigits ::
OctalDigit
OctalDigits OctalDigit
0
1
2
3
4
5
6
7
HexIntegerLiteral ::
0x
HexDigits
0X
HexDigits
HexDigits ::
HexDigit
HexDigits HexDigit
0
1
2
3
4
5
6
7
8
9
a
b
c
d
e
f
A
B
C
D
E
F
StringLiteral ::
"
DoubleStringCharactersopt "
'
SingleStringCharactersopt '
DoubleStringCharacters ::
DoubleStringCharacter DoubleStringCharactersopt
SingleStringCharacters ::
SingleStringCharacter SingleStringCharactersopt
DoubleStringCharacter ::
SourceCharacter but not one of "
or \
or LineTerminator
\
EscapeSequence
LineContinuation
SingleStringCharacter ::
SourceCharacter but not one of '
or \
or LineTerminator
\
EscapeSequence
LineContinuation
LineContinuation ::
\
LineTerminatorSequence
EscapeSequence ::
CharacterEscapeSequence
0
[lookahead ≠ DecimalDigit]
HexEscapeSequence
UnicodeEscapeSequence
CharacterEscapeSequence ::
SingleEscapeCharacter
NonEscapeCharacter
SingleEscapeCharacter :: one of
'
"
\
b
f
n
r
t
v
NonEscapeCharacter ::
SourceCharacter but not one of EscapeCharacter or LineTerminator
EscapeCharacter ::
SingleEscapeCharacter
DecimalDigit
x
u
HexEscapeSequence ::
x
HexDigit HexDigit
UnicodeEscapeSequence ::
u
Hex4Digits
u{
HexDigits }
Hex4Digits ::
HexDigit HexDigit HexDigit HexDigit
RegularExpressionLiteral ::
/
RegularExpressionBody /
RegularExpressionFlags
RegularExpressionBody ::
RegularExpressionFirstChar RegularExpressionChars
RegularExpressionChars ::
[empty]
RegularExpressionChars RegularExpressionChar
RegularExpressionFirstChar ::
RegularExpressionNonTerminator but not one of *
or \
or /
or [
RegularExpressionBackslashSequence
RegularExpressionClass
RegularExpressionChar ::
RegularExpressionNonTerminator but not one of \
or /
or [
RegularExpressionBackslashSequence
RegularExpressionClass
RegularExpressionBackslashSequence ::
\
RegularExpressionNonTerminator
RegularExpressionNonTerminator ::
SourceCharacter but not LineTerminator
RegularExpressionClass ::
[
RegularExpressionClassChars ]
RegularExpressionClassChars ::
[empty]
RegularExpressionClassChars RegularExpressionClassChar
RegularExpressionClassChar ::
RegularExpressionNonTerminator but not one of ]
or \
RegularExpressionBackslashSequence
RegularExpressionFlags ::
[empty]
RegularExpressionFlags IdentifierPart
Template ::
NoSubstitutionTemplate
TemplateHead
NoSubstitutionTemplate ::
`
TemplateCharactersopt `
TemplateHead ::
`
TemplateCharactersopt ${
TemplateSubstitutionTail ::
TemplateMiddle
TemplateTail
TemplateMiddle ::
}
TemplateCharactersopt ${
TemplateTail ::
}
TemplateCharactersopt `
TemplateCharacters ::
TemplateCharacter TemplateCharactersopt
TemplateCharacter ::
$
[lookahead ≠ {
]
\
EscapeSequence
LineContinuation
LineTerminatorSequence
SourceCharacter but not one of `
or \
or $
or LineTerminator
IdentifierReference[Yield] :
Identifier
[~Yield] yield
BindingIdentifier[Yield] :
Identifier
[~Yield] yield
LabelIdentifier[Yield] :
Identifier
[~Yield] yield
Identifier :
IdentifierName but not ReservedWord
PrimaryExpression[Yield] :
this
IdentifierReference[?Yield]
Literal
ArrayLiteral[?Yield]
ObjectLiteral[?Yield]
FunctionExpression
ClassExpression[?Yield]
GeneratorExpression
RegularExpressionLiteral
TemplateLiteral[?Yield]
CoverParenthesizedExpressionAndArrowParameterList[?Yield]
CoverParenthesizedExpressionAndArrowParameterList[Yield] :
(
Expression[In, ?Yield] )
(
)
(
...
BindingIdentifier[?Yield] )
(
Expression[In, ?Yield] ,
...
BindingIdentifier[?Yield] )
Literal :
NullLiteral
BooleanLiteral
NumericLiteral
StringLiteral
ArrayLiteral[Yield] :
[
Elisionopt ]
[
ElementList[?Yield] ]
[
ElementList[?Yield] ,
Elisionopt ]
ElementList[Yield] :
Elisionopt AssignmentExpression[In, ?Yield]
Elisionopt SpreadElement[?Yield]
ElementList[?Yield] ,
Elisionopt AssignmentExpression[In, ?Yield]
ElementList[?Yield] ,
Elisionopt SpreadElement[?Yield]
Elision :
,
Elision ,
SpreadElement[Yield] :
...
AssignmentExpression[In, ?Yield]
ObjectLiteral[Yield] :
{
}
{
PropertyDefinitionList[?Yield] }
{
PropertyDefinitionList[?Yield] ,
}
PropertyDefinitionList[Yield] :
PropertyDefinition[?Yield]
PropertyDefinitionList[?Yield] ,
PropertyDefinition[?Yield]
PropertyDefinition[Yield] :
IdentifierReference[?Yield]
CoverInitializedName[?Yield]
PropertyName[?Yield] :
AssignmentExpression[In, ?Yield]
MethodDefinition[?Yield]
PropertyName[Yield] :
LiteralPropertyName
ComputedPropertyName[?Yield]
LiteralPropertyName :
IdentifierName
StringLiteral
NumericLiteral
ComputedPropertyName[Yield] :
[
AssignmentExpression[In, ?Yield] ]
CoverInitializedName[Yield] :
IdentifierReference[?Yield] Initializer[In, ?Yield]
Initializer[In, Yield] :
=
AssignmentExpression[?In, ?Yield]
TemplateLiteral[Yield] :
NoSubstitutionTemplate
TemplateHead Expression[In, ?Yield] TemplateSpans[?Yield]
TemplateSpans[Yield] :
TemplateTail
TemplateMiddleList[?Yield] TemplateTail
TemplateMiddleList[Yield] :
TemplateMiddle Expression[In, ?Yield]
TemplateMiddleList[?Yield] TemplateMiddle Expression[In, ?Yield]
MemberExpression[Yield] :
PrimaryExpression[?Yield]
MemberExpression[?Yield] [
Expression[In, ?Yield] ]
MemberExpression[?Yield] .
IdentifierName
MemberExpression[?Yield] TemplateLiteral[?Yield]
SuperProperty[?Yield]
MetaProperty
new
MemberExpression[?Yield] Arguments[?Yield]
SuperProperty[Yield] :
super
[
Expression[In, ?Yield] ]
super
.
IdentifierName
MetaProperty :
NewTarget
NewExpression[Yield] :
MemberExpression[?Yield]
new
NewExpression[?Yield]
CallExpression[Yield] :
MemberExpression[?Yield] Arguments[?Yield]
SuperCall[?Yield]
CallExpression[?Yield] Arguments[?Yield]
CallExpression[?Yield] [
Expression[In, ?Yield] ]
CallExpression[?Yield] .
IdentifierName
CallExpression[?Yield] TemplateLiteral[?Yield]
SuperCall[Yield] :
super
Arguments[?Yield]
Arguments[Yield] :
(
)
(
ArgumentList[?Yield] )
ArgumentList[Yield] :
AssignmentExpression[In, ?Yield]
...
AssignmentExpression[In, ?Yield]
ArgumentList[?Yield] ,
AssignmentExpression[In, ?Yield]
ArgumentList[?Yield] ,
...
AssignmentExpression[In, ?Yield]
LeftHandSideExpression[Yield] :
NewExpression[?Yield]
CallExpression[?Yield]
PostfixExpression[Yield] :
LeftHandSideExpression[?Yield]
LeftHandSideExpression[?Yield] [no LineTerminator here] ++
LeftHandSideExpression[?Yield] [no LineTerminator here] --
UnaryExpression[Yield] :
PostfixExpression[?Yield]
delete
UnaryExpression[?Yield]
void
UnaryExpression[?Yield]
typeof
UnaryExpression[?Yield]
++
UnaryExpression[?Yield]
--
UnaryExpression[?Yield]
+
UnaryExpression[?Yield]
-
UnaryExpression[?Yield]
~
UnaryExpression[?Yield]
!
UnaryExpression[?Yield]
MultiplicativeExpression[Yield] :
UnaryExpression[?Yield]
MultiplicativeExpression[?Yield] MultiplicativeOperator UnaryExpression[?Yield]
MultiplicativeOperator : one of
*
/
%
AdditiveExpression[Yield] :
MultiplicativeExpression[?Yield]
AdditiveExpression[?Yield] +
MultiplicativeExpression[?Yield]
AdditiveExpression[?Yield] -
MultiplicativeExpression[?Yield]
ShiftExpression[Yield] :
AdditiveExpression[?Yield]
ShiftExpression[?Yield] <<
AdditiveExpression[?Yield]
ShiftExpression[?Yield] >>
AdditiveExpression[?Yield]
ShiftExpression[?Yield] >>>
AdditiveExpression[?Yield]
RelationalExpression[In, Yield] :
ShiftExpression[?Yield]
RelationalExpression[?In, ?Yield] <
ShiftExpression[?Yield]
RelationalExpression[?In, ?Yield] >
ShiftExpression[?Yield]
RelationalExpression[?In, ?Yield] <=
ShiftExpression[?Yield]
RelationalExpression[?In, ?Yield] >=
ShiftExpression[?Yield]
RelationalExpression[?In, ?Yield] instanceof
ShiftExpression[?Yield]
[+In] RelationalExpression[In, ?Yield] in
ShiftExpression[?Yield]
EqualityExpression[In, Yield] :
RelationalExpression[?In, ?Yield]
EqualityExpression[?In, ?Yield] ==
RelationalExpression[?In, ?Yield]
EqualityExpression[?In, ?Yield] !=
RelationalExpression[?In, ?Yield]
EqualityExpression[?In, ?Yield] ===
RelationalExpression[?In, ?Yield]
EqualityExpression[?In, ?Yield] !==
RelationalExpression[?In, ?Yield]
BitwiseANDExpression[In, Yield] :
EqualityExpression[?In, ?Yield]
BitwiseANDExpression[?In, ?Yield] &
EqualityExpression[?In, ?Yield]
BitwiseXORExpression[In, Yield] :
BitwiseANDExpression[?In, ?Yield]
BitwiseXORExpression[?In, ?Yield] ^
BitwiseANDExpression[?In, ?Yield]
BitwiseORExpression[In, Yield] :
BitwiseXORExpression[?In, ?Yield]
BitwiseORExpression[?In, ?Yield] |
BitwiseXORExpression[?In, ?Yield]
LogicalANDExpression[In, Yield] :
BitwiseORExpression[?In, ?Yield]
LogicalANDExpression[?In, ?Yield] &&
BitwiseORExpression[?In, ?Yield]
LogicalORExpression[In, Yield] :
LogicalANDExpression[?In, ?Yield]
LogicalORExpression[?In, ?Yield] ||
LogicalANDExpression[?In, ?Yield]
ConditionalExpression[In, Yield] :
LogicalORExpression[?In, ?Yield]
LogicalORExpression[?In, ?Yield] ?
AssignmentExpression[In, ?Yield] :
AssignmentExpression[?In, ?Yield]
AssignmentExpression[In, Yield] :
ConditionalExpression[?In, ?Yield]
[+Yield] YieldExpression[?In]
ArrowFunction[?In, ?Yield]
LeftHandSideExpression[?Yield] =
AssignmentExpression[?In, ?Yield]
LeftHandSideExpression[?Yield] AssignmentOperator AssignmentExpression[?In, ?Yield]
*=
/=
%=
+=
-=
<<=
>>=
>>>=
&=
^=
|=
Expression[In, Yield] :
AssignmentExpression[?In, ?Yield]
Expression[?In, ?Yield] ,
AssignmentExpression[?In, ?Yield]
Statement[Yield, Return] :
BlockStatement[?Yield, ?Return]
VariableStatement[?Yield]
EmptyStatement
ExpressionStatement[?Yield]
IfStatement[?Yield, ?Return]
BreakableStatement[?Yield, ?Return]
ContinueStatement[?Yield]
BreakStatement[?Yield]
[+Return] ReturnStatement[?Yield]
WithStatement[?Yield, ?Return]
LabelledStatement[?Yield, ?Return]
ThrowStatement[?Yield]
TryStatement[?Yield, ?Return]
DebuggerStatement
Declaration[Yield] :
HoistableDeclaration[?Yield]
ClassDeclaration[?Yield]
LexicalDeclaration[In, ?Yield]
HoistableDeclaration[Yield, Default] :
FunctionDeclaration[?Yield, ?Default]
GeneratorDeclaration[?Yield, ?Default]
BreakableStatement[Yield, Return] :
IterationStatement[?Yield, ?Return]
SwitchStatement[?Yield, ?Return]
BlockStatement[Yield, Return] :
Block[?Yield, ?Return]
Block[Yield, Return] :
{
StatementList[?Yield, ?Return]opt }
StatementList[Yield, Return] :
StatementListItem[?Yield, ?Return]
StatementList[?Yield, ?Return] StatementListItem[?Yield, ?Return]
StatementListItem[Yield, Return] :
Statement[?Yield, ?Return]
Declaration[?Yield]
LexicalDeclaration[In, Yield] :
LetOrConst BindingList[?In, ?Yield] ;
BindingList[In, Yield] :
LexicalBinding[?In, ?Yield]
BindingList[?In, ?Yield] ,
LexicalBinding[?In, ?Yield]
LexicalBinding[In, Yield] :
BindingIdentifier[?Yield] Initializer[?In, ?Yield]opt
BindingPattern[?Yield] Initializer[?In, ?Yield]
VariableStatement[Yield] :
var
VariableDeclarationList[In, ?Yield] ;
VariableDeclarationList[In, Yield] :
VariableDeclaration[?In, ?Yield]
VariableDeclarationList[?In, ?Yield] ,
VariableDeclaration[?In, ?Yield]
VariableDeclaration[In, Yield] :
BindingIdentifier[?Yield] Initializer[?In, ?Yield]opt
BindingPattern[?Yield] Initializer[?In, ?Yield]
BindingPattern[Yield] :
ObjectBindingPattern[?Yield]
ArrayBindingPattern[?Yield]
ObjectBindingPattern[Yield] :
{
}
{
BindingPropertyList[?Yield] }
{
BindingPropertyList[?Yield] ,
}
ArrayBindingPattern[Yield] :
[
Elisionopt BindingRestElement[?Yield]opt ]
[
BindingElementList[?Yield] ]
[
BindingElementList[?Yield] ,
Elisionopt BindingRestElement[?Yield]opt ]
BindingPropertyList[Yield] :
BindingProperty[?Yield]
BindingPropertyList[?Yield] ,
BindingProperty[?Yield]
BindingElementList[Yield] :
BindingElisionElement[?Yield]
BindingElementList[?Yield] ,
BindingElisionElement[?Yield]
BindingElisionElement[Yield] :
Elisionopt BindingElement[?Yield]
BindingProperty[Yield] :
SingleNameBinding[?Yield]
PropertyName[?Yield] :
BindingElement[?Yield]
BindingElement[Yield] :
SingleNameBinding[?Yield]
BindingPattern[?Yield] Initializer[In, ?Yield]opt
SingleNameBinding[Yield] :
BindingIdentifier[?Yield] Initializer[In, ?Yield]opt
BindingRestElement[Yield] :
...
BindingIdentifier[?Yield]
ExpressionStatement[Yield] :
[lookahead ∉ { {
, function
, class
, let
[
}] Expression[In, ?Yield] ;
IfStatement[Yield, Return] :
if
(
Expression[In, ?Yield] )
Statement[?Yield, ?Return] else
Statement[?Yield, ?Return]
if
(
Expression[In, ?Yield] )
Statement[?Yield, ?Return]
IterationStatement[Yield, Return] :
do
Statement[?Yield, ?Return] while
(
Expression[In, ?Yield] )
;
while
(
Expression[In, ?Yield] )
Statement[?Yield, ?Return]
for
(
[lookahead ∉ { let
[
}] Expression[?Yield]opt ;
Expression[In, ?Yield]opt ;
Expression[In, ?Yield]opt )
Statement[?Yield, ?Return]
for
(
var
VariableDeclarationList[?Yield] ;
Expression[In, ?Yield]opt ;
Expression[In, ?Yield]opt )
Statement[?Yield, ?Return]
for
(
LexicalDeclaration[?Yield] Expression[In, ?Yield]opt ;
Expression[In, ?Yield]opt )
Statement[?Yield, ?Return]
for
(
[lookahead ∉ { let
[
}] LeftHandSideExpression[?Yield] in
Expression[In, ?Yield] )
Statement[?Yield, ?Return]
for
(
var
ForBinding[?Yield] in
Expression[In, ?Yield] )
Statement[?Yield, ?Return]
for
(
ForDeclaration[?Yield] in
Expression[In, ?Yield] )
Statement[?Yield, ?Return]
for
(
[lookahead ≠ let
] LeftHandSideExpression[?Yield] of
AssignmentExpression[In, ?Yield] )
Statement[?Yield, ?Return]
for
(
var
ForBinding[?Yield] of
AssignmentExpression[In, ?Yield] )
Statement[?Yield, ?Return]
for
(
ForDeclaration[?Yield] of
AssignmentExpression[In, ?Yield] )
Statement[?Yield, ?Return]
ForDeclaration[Yield] :
LetOrConst ForBinding[?Yield]
ForBinding[Yield] :
BindingIdentifier[?Yield]
BindingPattern[?Yield]
ContinueStatement[Yield] :
continue
;
continue
[no LineTerminator here] LabelIdentifier[?Yield] ;
BreakStatement[Yield] :
break
;
break
[no LineTerminator here] LabelIdentifier[?Yield] ;
ReturnStatement[Yield] :
return
;
return
[no LineTerminator here] Expression[In, ?Yield] ;
WithStatement[Yield, Return] :
with
(
Expression[In, ?Yield] )
Statement[?Yield, ?Return]
SwitchStatement[Yield, Return] :
switch
(
Expression[In, ?Yield] )
CaseBlock[?Yield, ?Return]
CaseBlock[Yield, Return] :
{
CaseClauses[?Yield, ?Return]opt }
{
CaseClauses[?Yield, ?Return]opt DefaultClause[?Yield, ?Return] CaseClauses[?Yield, ?Return]opt }
CaseClauses[Yield, Return] :
CaseClause[?Yield, ?Return]
CaseClauses[?Yield, ?Return] CaseClause[?Yield, ?Return]
CaseClause[Yield, Return] :
case
Expression[In, ?Yield] :
StatementList[?Yield, ?Return]opt
DefaultClause[Yield, Return] :
default
:
StatementList[?Yield, ?Return]opt
LabelledStatement[Yield, Return] :
LabelIdentifier[?Yield] :
LabelledItem[?Yield, ?Return]
LabelledItem[Yield, Return] :
Statement[?Yield, ?Return]
FunctionDeclaration[?Yield]
ThrowStatement[Yield] :
throw
[no LineTerminator here] Expression[In, ?Yield] ;
TryStatement[Yield, Return] :
try
Block[?Yield, ?Return] Catch[?Yield, ?Return]
try
Block[?Yield, ?Return] Finally[?Yield, ?Return]
try
Block[?Yield, ?Return] Catch[?Yield, ?Return] Finally[?Yield, ?Return]
Catch[Yield, Return] :
catch
(
CatchParameter[?Yield] )
Block[?Yield, ?Return]
Finally[Yield, Return] :
finally
Block[?Yield, ?Return]
CatchParameter[Yield] :
BindingIdentifier[?Yield]
BindingPattern[?Yield]
DebuggerStatement :
debugger
;
FunctionDeclaration[Yield, Default] :
function
BindingIdentifier[?Yield] (
FormalParameters )
{
FunctionBody }
[+Default] function
(
FormalParameters )
{
FunctionBody }
FunctionExpression :
function
BindingIdentifieropt (
FormalParameters )
{
FunctionBody }
StrictFormalParameters[Yield] :
FormalParameters[?Yield]
FormalParameters[Yield] :
[empty]
FormalParameterList[?Yield]
FormalParameterList[Yield] :
FunctionRestParameter[?Yield]
FormalsList[?Yield]
FormalsList[?Yield] ,
FunctionRestParameter[?Yield]
FormalsList[Yield] :
FormalParameter[?Yield]
FormalsList[?Yield] ,
FormalParameter[?Yield]
FunctionRestParameter[Yield] :
BindingRestElement[?Yield]
FormalParameter[Yield] :
BindingElement[?Yield]
FunctionBody[Yield] :
FunctionStatementList[?Yield]
FunctionStatementList[Yield] :
StatementList[?Yield, Return]opt
ArrowFunction[In, Yield] :
ArrowParameters[?Yield] [no LineTerminator here] =>
ConciseBody[?In]
ArrowParameters[Yield] :
BindingIdentifier[?Yield]
CoverParenthesizedExpressionAndArrowParameterList[?Yield]
ConciseBody[In] :
[lookahead ≠ {
] AssignmentExpression[?In]
{
FunctionBody }
MethodDefinition[Yield] :
PropertyName[?Yield] (
StrictFormalParameters )
{
FunctionBody }
GeneratorMethod[?Yield]
get
PropertyName[?Yield] (
)
{
FunctionBody }
set
PropertyName[?Yield] (
PropertySetParameterList )
{
FunctionBody }
PropertySetParameterList :
FormalParameter
GeneratorMethod[Yield] :
*
PropertyName[?Yield] (
StrictFormalParameters[Yield] )
{
GeneratorBody }
GeneratorDeclaration[Yield, Default] :
function
*
BindingIdentifier[?Yield] (
FormalParameters[Yield] )
{
GeneratorBody }
[+Default] function
*
(
FormalParameters[Yield] )
{
GeneratorBody }
GeneratorExpression :
function
*
BindingIdentifier[Yield]opt (
FormalParameters[Yield] )
{
GeneratorBody }
GeneratorBody :
FunctionBody[Yield]
YieldExpression[In] :
yield
yield
[no LineTerminator here] AssignmentExpression[?In, Yield]
yield
[no LineTerminator here] *
AssignmentExpression[?In, Yield]
ClassDeclaration[Yield, Default] :
class
BindingIdentifier[?Yield] ClassTail[?Yield]
[+Default] class
ClassTail[?Yield]
ClassExpression[Yield] :
class
BindingIdentifier[?Yield]opt ClassTail[?Yield]
ClassTail[Yield] :
ClassHeritage[?Yield]opt {
ClassBody[?Yield]opt }
ClassHeritage[Yield] :
extends
LeftHandSideExpression[?Yield]
ClassBody[Yield] :
ClassElementList[?Yield]
ClassElementList[Yield] :
ClassElement[?Yield]
ClassElementList[?Yield] ClassElement[?Yield]
ClassElement[Yield] :
MethodDefinition[?Yield]
static
MethodDefinition[?Yield]
;
Script :
ScriptBodyopt
ScriptBody :
StatementList
Module :
ModuleBodyopt
ModuleBody :
ModuleItemList
ModuleItemList :
ModuleItem
ModuleItemList ModuleItem
ModuleItem :
ImportDeclaration
ExportDeclaration
StatementListItem
ImportDeclaration :
import
ImportClause FromClause ;
import
ModuleSpecifier ;
ImportClause :
ImportedDefaultBinding
NameSpaceImport
NamedImports
ImportedDefaultBinding ,
NameSpaceImport
ImportedDefaultBinding ,
NamedImports
ImportedDefaultBinding :
ImportedBinding
NameSpaceImport :
*
as
ImportedBinding
NamedImports :
{
}
{
ImportsList }
{
ImportsList ,
}
FromClause :
from
ModuleSpecifier
ImportsList :
ImportSpecifier
ImportsList ,
ImportSpecifier
ImportSpecifier :
ImportedBinding
IdentifierName as
ImportedBinding
ModuleSpecifier :
StringLiteral
ImportedBinding :
BindingIdentifier
ExportDeclaration :
export
*
FromClause ;
export
ExportClause FromClause ;
export
ExportClause ;
export
VariableStatement
export
Declaration
export
default
HoistableDeclaration[Default]
export
default
ClassDeclaration[Default]
export
default
[lookahead ∉ { function
, class
}] AssignmentExpression[In] ;
ExportClause :
{
}
{
ExportsList }
{
ExportsList ,
}
ExportsList :
ExportSpecifier
ExportsList ,
ExportSpecifier
ExportSpecifier :
IdentifierName
IdentifierName as
IdentifierName