Recovery for expressions. Bug with return inside if fixed
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
val f = if (true) return else {
|
||||
dfsd
|
||||
);;;);;;~;;;
|
||||
srgsdfg
|
||||
|
||||
~
|
||||
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,58 @@
|
||||
JetFile: Expressions_ERR.jet
|
||||
NAMESPACE
|
||||
PROPERTY
|
||||
PsiElement(val)('val')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(EQ)('=')
|
||||
PsiWhiteSpace(' ')
|
||||
IF
|
||||
PsiElement(if)('if')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(LPAR)('(')
|
||||
CONDITION
|
||||
BOOLEAN_CONSTANT
|
||||
PsiElement(true)('true')
|
||||
PsiElement(RPAR)(')')
|
||||
PsiWhiteSpace(' ')
|
||||
THEN
|
||||
RETURN
|
||||
PsiElement(return)('return')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(else)('else')
|
||||
PsiWhiteSpace(' ')
|
||||
ELSE
|
||||
FUNCTION_LITERAL
|
||||
PsiElement(LBRACE)('{')
|
||||
PsiWhiteSpace('\n ')
|
||||
BODY
|
||||
REFERENCE_EXPRESSION
|
||||
PsiElement(IDENTIFIER)('dfsd')
|
||||
PsiWhiteSpace('\n ')
|
||||
PsiErrorElement:Expecting an expression
|
||||
PsiElement(RPAR)(')')
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiErrorElement:Expecting an expression
|
||||
PsiElement(RPAR)(')')
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiErrorElement:Expecting an expression
|
||||
PsiElement(BAD_CHARACTER)('~')
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiWhiteSpace('\n ')
|
||||
REFERENCE_EXPRESSION
|
||||
PsiElement(IDENTIFIER)('srgsdfg')
|
||||
PsiWhiteSpace('\n\n ')
|
||||
PsiErrorElement:Expecting an expression
|
||||
PsiElement(BAD_CHARACTER)('~')
|
||||
PsiWhiteSpace('\n\n ')
|
||||
PsiErrorElement:Expecting an expression
|
||||
PsiElement(RBRACKET)(']')
|
||||
PsiWhiteSpace('\n')
|
||||
PsiElement(RBRACE)('}')
|
||||
@@ -152,9 +152,10 @@ JetFile: When_ERR.jet
|
||||
<empty list>
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(DOUBLE_ARROW)('=>')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiErrorElement:Expecting an expression
|
||||
PsiElement(SEMICOLON)(';')
|
||||
<empty list>
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiWhiteSpace('\n ')
|
||||
WHEN_ENTRY
|
||||
WHEN_CONDITION
|
||||
|
||||
Reference in New Issue
Block a user