Skip to content

Annex A (informative) Grammar Summary

A.1 Lexical Grammar

await is only treated as a FutureReservedWord when Module is the goal symbol of the syntactic grammar.

The following tokens are also considered to be FutureReservedWords when parsing strict mode code:

implements  package  protected
interface  private  public

 

A.2 Expressions

When processing an instance of the production the interpretation of CoverParenthesizedExpressionAndArrowParameterList is refined using the following grammar:

 

When processing an instance of the production the interpretation of CoverCallExpressionAndAsyncArrowHead is refined using the following grammar:

 

In certain circumstances when processing an instance of the production the following grammar is used to refine the interpretation of LeftHandSideExpression:

 

A.3 Statements

A.4 Functions and Classes

When the production is recognized the following grammar is used to refine the interpretation of CoverParenthesizedExpressionAndArrowParameterList:

 

When the production is recognized the following grammar is used to refine the interpretation of CoverParenthesizedExpressionAndArrowParameterList:

 

A.5 Scripts and Modules

A.6 Number Conversions

All grammar symbols not explicitly defined by the StringNumericLiteral grammar have the definitions used in the Lexical Grammar for numeric literals.

A.7 Universal Resource Identifier Character Classes

A.8 Regular Expressions

Each \u TrailSurrogate for which the choice of associated u LeadSurrogate is ambiguous shall be associated with the nearest possible u LeadSurrogate that would otherwise have no corresponding \u TrailSurrogate.