Skip to content
Merged
48 changes: 27 additions & 21 deletions bins/estree/src/builder/actions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2245,20 +2245,22 @@
StatementListItem_Yield_Await_Return
action: append_to_list
- rule: >-
MethodDefinition -> ClassElementName LPAREN UniqueFormalParameters RPAREN LBRACE FunctionBody
RBRACE
MethodDefinition -> ClassElementName _FUNCTION_CONTEXT_ LPAREN UniqueFormalParameters RPAREN
_FUNCTION_SIGNATURE_ LBRACE FunctionBody RBRACE
action: method_definition
- rule: MethodDefinition -> GeneratorMethod
action: nop
- rule: MethodDefinition -> AsyncMethod
action: nop
- rule: MethodDefinition -> AsyncGeneratorMethod
action: nop
- rule: MethodDefinition -> GET ClassElementName LPAREN RPAREN LBRACE FunctionBody RBRACE
- rule: >-
MethodDefinition -> GET ClassElementName _FUNCTION_CONTEXT_ LPAREN RPAREN _FUNCTION_SIGNATURE_
LBRACE FunctionBody RBRACE
action: method_definition_get
- rule: >-
MethodDefinition -> SET ClassElementName LPAREN PropertySetParameterList RPAREN LBRACE
FunctionBody RBRACE
MethodDefinition -> SET ClassElementName _FUNCTION_CONTEXT_ LPAREN PropertySetParameterList
RPAREN _FUNCTION_SIGNATURE_ LBRACE FunctionBody RBRACE
action: method_definition_set
- rule: FieldDefinition -> ClassElementName
action: property_definition
Expand All @@ -2267,20 +2269,22 @@
- rule: ClassStaticBlock -> STATIC LBRACE ClassStaticBlockBody RBRACE
action: static_block
- rule: >-
MethodDefinition_Await -> ClassElementName_Await LPAREN UniqueFormalParameters RPAREN LBRACE
FunctionBody RBRACE
MethodDefinition_Await -> ClassElementName_Await _FUNCTION_CONTEXT_ LPAREN
UniqueFormalParameters RPAREN _FUNCTION_SIGNATURE_ LBRACE FunctionBody RBRACE
action: method_definition
- rule: MethodDefinition_Await -> GeneratorMethod_Await
action: nop
- rule: MethodDefinition_Await -> AsyncMethod_Await
action: nop
- rule: MethodDefinition_Await -> AsyncGeneratorMethod_Await
action: nop
- rule: MethodDefinition_Await -> GET ClassElementName_Await LPAREN RPAREN LBRACE FunctionBody RBRACE
- rule: >-
MethodDefinition_Await -> GET ClassElementName_Await _FUNCTION_CONTEXT_ LPAREN RPAREN
_FUNCTION_SIGNATURE_ LBRACE FunctionBody RBRACE
action: method_definition_get
- rule: >-
MethodDefinition_Await -> SET ClassElementName_Await LPAREN PropertySetParameterList RPAREN
LBRACE FunctionBody RBRACE
MethodDefinition_Await -> SET ClassElementName_Await _FUNCTION_CONTEXT_ LPAREN
PropertySetParameterList RPAREN _FUNCTION_SIGNATURE_ LBRACE FunctionBody RBRACE
action: method_definition_set
- rule: FieldDefinition_Await -> ClassElementName_Await
action: property_definition
Expand Down Expand Up @@ -4525,20 +4529,22 @@
- rule: CoverInitializedName_Yield -> IdentifierReference_Yield Initializer_In_Yield
action: cover_initialized_name
- rule: >-
MethodDefinition_Yield -> ClassElementName_Yield LPAREN UniqueFormalParameters RPAREN LBRACE
FunctionBody RBRACE
MethodDefinition_Yield -> ClassElementName_Yield _FUNCTION_CONTEXT_ LPAREN
UniqueFormalParameters RPAREN _FUNCTION_SIGNATURE_ LBRACE FunctionBody RBRACE
action: method_definition
- rule: MethodDefinition_Yield -> GeneratorMethod_Yield
action: nop
- rule: MethodDefinition_Yield -> AsyncMethod_Yield
action: nop
- rule: MethodDefinition_Yield -> AsyncGeneratorMethod_Yield
action: nop
- rule: MethodDefinition_Yield -> GET ClassElementName_Yield LPAREN RPAREN LBRACE FunctionBody RBRACE
- rule: >-
MethodDefinition_Yield -> GET ClassElementName_Yield _FUNCTION_CONTEXT_ LPAREN RPAREN
_FUNCTION_SIGNATURE_ LBRACE FunctionBody RBRACE
action: method_definition_get
- rule: >-
MethodDefinition_Yield -> SET ClassElementName_Yield LPAREN PropertySetParameterList RPAREN
LBRACE FunctionBody RBRACE
MethodDefinition_Yield -> SET ClassElementName_Yield _FUNCTION_CONTEXT_ LPAREN
PropertySetParameterList RPAREN _FUNCTION_SIGNATURE_ LBRACE FunctionBody RBRACE
action: method_definition_set
- rule: ClassElementList_Yield -> ClassElement_Yield
action: class_element_list
Expand Down Expand Up @@ -4581,8 +4587,8 @@
- rule: CoverInitializedName_Yield_Await -> IdentifierReference_Yield_Await Initializer_In_Yield_Await
action: cover_initialized_name
- rule: >-
MethodDefinition_Yield_Await -> ClassElementName_Yield_Await LPAREN UniqueFormalParameters
RPAREN LBRACE FunctionBody RBRACE
MethodDefinition_Yield_Await -> ClassElementName_Yield_Await _FUNCTION_CONTEXT_ LPAREN
UniqueFormalParameters RPAREN _FUNCTION_SIGNATURE_ LBRACE FunctionBody RBRACE
action: method_definition
- rule: MethodDefinition_Yield_Await -> GeneratorMethod_Yield_Await
action: nop
Expand All @@ -4591,12 +4597,12 @@
- rule: MethodDefinition_Yield_Await -> AsyncGeneratorMethod_Yield_Await
action: nop
- rule: >-
MethodDefinition_Yield_Await -> GET ClassElementName_Yield_Await LPAREN RPAREN LBRACE
FunctionBody RBRACE
MethodDefinition_Yield_Await -> GET ClassElementName_Yield_Await _FUNCTION_CONTEXT_ LPAREN
RPAREN _FUNCTION_SIGNATURE_ LBRACE FunctionBody RBRACE
action: method_definition_get
- rule: >-
MethodDefinition_Yield_Await -> SET ClassElementName_Yield_Await LPAREN
PropertySetParameterList RPAREN LBRACE FunctionBody RBRACE
MethodDefinition_Yield_Await -> SET ClassElementName_Yield_Await _FUNCTION_CONTEXT_ LPAREN
PropertySetParameterList RPAREN _FUNCTION_SIGNATURE_ LBRACE FunctionBody RBRACE
action: method_definition_set
- rule: ClassElementList_Yield_Await -> ClassElement_Yield_Await
action: class_element_list
Expand Down
14 changes: 14 additions & 0 deletions libs/jsparser/src/symbol/builtin.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,24 +56,33 @@
- [async, ASYNC]
- all
- arguments
- assign
- at
- cause
- charAt
- charCodeAt
- codePointAt
- concat
- configurable
- constructor
- create
- default
- defineProperties
- defineProperty
- endsWith
- enumerable
- eval
- fromCharCode
- fromCodePoint
- get
- globalThis
- hasOwnProperty
- includes
- indexOf
- isError
- isFinite
- [isNaN, IS_NAN]
- isPrototypeOf
- isWellFormed
- lastIndexOf
- length
Expand All @@ -83,14 +92,19 @@
- padStart
- parseFloat
- parseInt
- propertyIsEnumerable
- prototype
- repeat
- set
- startsWith
- substring
- toString
- trim
- trimEnd
- trimStart
- value
- valueOf
- writable

# Special symbols for internal use only.
- ['-Infinity', NEG_INFINITY]
89 changes: 49 additions & 40 deletions libs/jsparser/src/syntax/actions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2468,22 +2468,24 @@
StatementListItem_Yield_Await_Return
action: process_statement_list_item
- rule: >-
MethodDefinition -> ClassElementName LPAREN UniqueFormalParameters RPAREN
LBRACE FunctionBody RBRACE
action: undefined
MethodDefinition -> ClassElementName _FUNCTION_CONTEXT_ LPAREN
UniqueFormalParameters RPAREN _FUNCTION_SIGNATURE_ LBRACE FunctionBody
RBRACE
action: process_method_definition
- rule: MethodDefinition -> GeneratorMethod
action: undefined
- rule: MethodDefinition -> AsyncMethod
action: undefined
- rule: MethodDefinition -> AsyncGeneratorMethod
action: undefined
- rule: >-
MethodDefinition -> GET ClassElementName LPAREN RPAREN LBRACE FunctionBody
RBRACE
MethodDefinition -> GET ClassElementName _FUNCTION_CONTEXT_ LPAREN RPAREN
_FUNCTION_SIGNATURE_ LBRACE FunctionBody RBRACE
action: undefined
- rule: >-
MethodDefinition -> SET ClassElementName LPAREN PropertySetParameterList
RPAREN LBRACE FunctionBody RBRACE
MethodDefinition -> SET ClassElementName _FUNCTION_CONTEXT_ LPAREN
PropertySetParameterList RPAREN _FUNCTION_SIGNATURE_ LBRACE FunctionBody
RBRACE
action: undefined
- rule: FieldDefinition -> ClassElementName
action: undefined
Expand All @@ -2492,22 +2494,24 @@
- rule: ClassStaticBlock -> STATIC LBRACE ClassStaticBlockBody RBRACE
action: undefined
- rule: >-
MethodDefinition_Await -> ClassElementName_Await LPAREN
UniqueFormalParameters RPAREN LBRACE FunctionBody RBRACE
action: undefined
MethodDefinition_Await -> ClassElementName_Await _FUNCTION_CONTEXT_ LPAREN
UniqueFormalParameters RPAREN _FUNCTION_SIGNATURE_ LBRACE FunctionBody
RBRACE
action: process_method_definition
- rule: MethodDefinition_Await -> GeneratorMethod_Await
action: undefined
- rule: MethodDefinition_Await -> AsyncMethod_Await
action: undefined
- rule: MethodDefinition_Await -> AsyncGeneratorMethod_Await
action: undefined
- rule: >-
MethodDefinition_Await -> GET ClassElementName_Await LPAREN RPAREN LBRACE
FunctionBody RBRACE
MethodDefinition_Await -> GET ClassElementName_Await _FUNCTION_CONTEXT_
LPAREN RPAREN _FUNCTION_SIGNATURE_ LBRACE FunctionBody RBRACE
action: undefined
- rule: >-
MethodDefinition_Await -> SET ClassElementName_Await LPAREN
PropertySetParameterList RPAREN LBRACE FunctionBody RBRACE
MethodDefinition_Await -> SET ClassElementName_Await _FUNCTION_CONTEXT_
LPAREN PropertySetParameterList RPAREN _FUNCTION_SIGNATURE_ LBRACE
FunctionBody RBRACE
action: undefined
- rule: FieldDefinition_Await -> ClassElementName_Await
action: undefined
Expand Down Expand Up @@ -3046,9 +3050,9 @@
- rule: StatementListItem_Yield_Await_Return -> Declaration_Yield_Await
action: nop
- rule: ClassElementName -> PropertyName
action: undefined
action: process_class_element_name_property_name
- rule: ClassElementName -> PRIVATE_IDENTIFIER
action: undefined
action: process_class_element_name_private_identifier
- rule: >-
GeneratorMethod -> MUL ClassElementName LPAREN UniqueFormalParameters_Yield
RPAREN LBRACE GeneratorBody RBRACE
Expand All @@ -3067,9 +3071,9 @@
- rule: ClassStaticBlockBody -> ClassStaticBlockStatementList
action: undefined
- rule: ClassElementName_Await -> PropertyName_Await
action: undefined
action: process_class_element_name_property_name
- rule: ClassElementName_Await -> PRIVATE_IDENTIFIER
action: undefined
action: process_class_element_name_private_identifier
- rule: >-
GeneratorMethod_Await -> MUL ClassElementName_Await LPAREN
UniqueFormalParameters_Yield RPAREN LBRACE GeneratorBody RBRACE
Expand Down Expand Up @@ -3519,7 +3523,7 @@
AssignmentExpression_In_Await
action: process_property_definition_key_value
- rule: PropertyDefinition_Await -> MethodDefinition_Await
action: undefined
action: process_property_definition_method
- rule: PropertyDefinition_Await -> ELLIPSIS AssignmentExpression_In_Await
action: process_property_definition_spread
- rule: _TO_STRING_ -> (empty)
Expand Down Expand Up @@ -4097,7 +4101,7 @@
- rule: PropertyDefinition -> PropertyName COLON AssignmentExpression_In
action: process_property_definition_key_value
- rule: PropertyDefinition -> MethodDefinition
action: undefined
action: process_property_definition_method
- rule: PropertyDefinition -> ELLIPSIS AssignmentExpression_In
action: process_property_definition_spread
- rule: TemplateSpans -> _TEMPLATE_TAIL_
Expand Down Expand Up @@ -4440,7 +4444,7 @@
AssignmentExpression_In_Yield
action: process_property_definition_key_value
- rule: PropertyDefinition_Yield -> MethodDefinition_Yield
action: undefined
action: process_property_definition_method
- rule: PropertyDefinition_Yield -> ELLIPSIS AssignmentExpression_In_Yield
action: process_property_definition_spread
- rule: ClassHeritage_Yield -> EXTENDS LeftHandSideExpression_Yield
Expand Down Expand Up @@ -4480,7 +4484,7 @@
AssignmentExpression_In_Yield_Await
action: process_property_definition_key_value
- rule: PropertyDefinition_Yield_Await -> MethodDefinition_Yield_Await
action: undefined
action: process_property_definition_method
- rule: >-
PropertyDefinition_Yield_Await -> ELLIPSIS
AssignmentExpression_In_Yield_Await
Expand Down Expand Up @@ -5067,22 +5071,24 @@
- rule: CoverInitializedName_Yield -> IdentifierReference_Yield Initializer_In_Yield
action: process_cover_initialized_name
- rule: >-
MethodDefinition_Yield -> ClassElementName_Yield LPAREN
UniqueFormalParameters RPAREN LBRACE FunctionBody RBRACE
action: undefined
MethodDefinition_Yield -> ClassElementName_Yield _FUNCTION_CONTEXT_ LPAREN
UniqueFormalParameters RPAREN _FUNCTION_SIGNATURE_ LBRACE FunctionBody
RBRACE
action: process_method_definition
- rule: MethodDefinition_Yield -> GeneratorMethod_Yield
action: undefined
- rule: MethodDefinition_Yield -> AsyncMethod_Yield
action: undefined
- rule: MethodDefinition_Yield -> AsyncGeneratorMethod_Yield
action: undefined
- rule: >-
MethodDefinition_Yield -> GET ClassElementName_Yield LPAREN RPAREN LBRACE
FunctionBody RBRACE
MethodDefinition_Yield -> GET ClassElementName_Yield _FUNCTION_CONTEXT_
LPAREN RPAREN _FUNCTION_SIGNATURE_ LBRACE FunctionBody RBRACE
action: undefined
- rule: >-
MethodDefinition_Yield -> SET ClassElementName_Yield LPAREN
PropertySetParameterList RPAREN LBRACE FunctionBody RBRACE
MethodDefinition_Yield -> SET ClassElementName_Yield _FUNCTION_CONTEXT_
LPAREN PropertySetParameterList RPAREN _FUNCTION_SIGNATURE_ LBRACE
FunctionBody RBRACE
action: undefined
- rule: ClassElementList_Yield -> ClassElement_Yield
action: undefined
Expand Down Expand Up @@ -5131,22 +5137,25 @@
Initializer_In_Yield_Await
action: process_cover_initialized_name
- rule: >-
MethodDefinition_Yield_Await -> ClassElementName_Yield_Await LPAREN
UniqueFormalParameters RPAREN LBRACE FunctionBody RBRACE
action: undefined
MethodDefinition_Yield_Await -> ClassElementName_Yield_Await
_FUNCTION_CONTEXT_ LPAREN UniqueFormalParameters RPAREN _FUNCTION_SIGNATURE_
LBRACE FunctionBody RBRACE
action: process_method_definition
- rule: MethodDefinition_Yield_Await -> GeneratorMethod_Yield_Await
action: undefined
- rule: MethodDefinition_Yield_Await -> AsyncMethod_Yield_Await
action: undefined
- rule: MethodDefinition_Yield_Await -> AsyncGeneratorMethod_Yield_Await
action: undefined
- rule: >-
MethodDefinition_Yield_Await -> GET ClassElementName_Yield_Await LPAREN
RPAREN LBRACE FunctionBody RBRACE
MethodDefinition_Yield_Await -> GET ClassElementName_Yield_Await
_FUNCTION_CONTEXT_ LPAREN RPAREN _FUNCTION_SIGNATURE_ LBRACE FunctionBody
RBRACE
action: undefined
- rule: >-
MethodDefinition_Yield_Await -> SET ClassElementName_Yield_Await LPAREN
PropertySetParameterList RPAREN LBRACE FunctionBody RBRACE
MethodDefinition_Yield_Await -> SET ClassElementName_Yield_Await
_FUNCTION_CONTEXT_ LPAREN PropertySetParameterList RPAREN
_FUNCTION_SIGNATURE_ LBRACE FunctionBody RBRACE
action: undefined
- rule: ClassElementList_Yield_Await -> ClassElement_Yield_Await
action: undefined
Expand Down Expand Up @@ -5293,9 +5302,9 @@
- rule: ShiftExpression_Yield -> ShiftExpression_Yield SHR AdditiveExpression_Yield
action: process_unsigned_right_shift
- rule: ClassElementName_Yield -> PropertyName_Yield
action: undefined
action: process_class_element_name_property_name
- rule: ClassElementName_Yield -> PRIVATE_IDENTIFIER
action: undefined
action: process_class_element_name_private_identifier
- rule: >-
GeneratorMethod_Yield -> MUL ClassElementName_Yield LPAREN
UniqueFormalParameters_Yield RPAREN LBRACE GeneratorBody RBRACE
Expand Down Expand Up @@ -5337,9 +5346,9 @@
AdditiveExpression_Yield_Await
action: process_unsigned_right_shift
- rule: ClassElementName_Yield_Await -> PropertyName_Yield_Await
action: undefined
action: process_class_element_name_property_name
- rule: ClassElementName_Yield_Await -> PRIVATE_IDENTIFIER
action: undefined
action: process_class_element_name_private_identifier
- rule: >-
GeneratorMethod_Yield_Await -> MUL ClassElementName_Yield_Await LPAREN
UniqueFormalParameters_Yield RPAREN LBRACE GeneratorBody RBRACE
Expand Down
Loading
Loading