fix: 语法问题
This commit is contained in:
@@ -291,14 +291,16 @@ private FieldDeclaration ::= PropertyName ':' Type
|
|||||||
CodeBlock ::= '{' Statement* '}'{
|
CodeBlock ::= '{' Statement* '}'{
|
||||||
pin=1
|
pin=1
|
||||||
}
|
}
|
||||||
private Statement ::= (ReturnStatement|IfElseStatement|ExpressionStatement) ';'?{
|
private Statement ::= (ReturnStatement|IfElseStatement|ExpressionStatement) ';'*{
|
||||||
recoverWhile=recoverWhileForComponentBody
|
}
|
||||||
|
ExpressionStatement ::= Expression (';'+ | &'}') {
|
||||||
|
pin=1
|
||||||
|
// recoverWhile=recoverWhileForComponentBody
|
||||||
}
|
}
|
||||||
ExpressionStatement ::= Expression (';' &Statement)?
|
|
||||||
|
|
||||||
//private recoverWhileStatement::=!(GenericIdentifier|';'|'}')
|
//private recoverWhileStatement::=!(GenericIdentifier|';'|'}')
|
||||||
|
|
||||||
ReturnStatement ::= 'return' (Expression)?{
|
ReturnStatement ::= ReturnKeyword (Expression)?{
|
||||||
pin=1
|
pin=1
|
||||||
}
|
}
|
||||||
private IfElseStatement ::= IfStatement (ElseIfStatement)* ElseStatement?{
|
private IfElseStatement ::= IfStatement (ElseIfStatement)* ElseStatement?{
|
||||||
@@ -504,7 +506,7 @@ AnimateKeyword::='animate'
|
|||||||
OutKeyword::='out'
|
OutKeyword::='out'
|
||||||
InOutKeyword::='in-out'
|
InOutKeyword::='in-out'
|
||||||
PrivateKeyword::='private'
|
PrivateKeyword::='private'
|
||||||
|
ReturnKeyword::='return'
|
||||||
//---------NamedIdentifier ,简化PsiTree-----------------------------------
|
//---------NamedIdentifier ,简化PsiTree-----------------------------------
|
||||||
//noinspection BnfUnusedRule 用于标记命名节点对应的identifier
|
//noinspection BnfUnusedRule 用于标记命名节点对应的identifier
|
||||||
Named ::= PropertyName | TypeName |ExternalName | InternalName|ComponentName|FunctionName{
|
Named ::= PropertyName | TypeName |ExternalName | InternalName|ComponentName|FunctionName{
|
||||||
|
|||||||
Reference in New Issue
Block a user