[Parser] Add additional parsing tests

This commit is contained in:
Victor Petukhov
2022-05-24 10:31:17 +02:00
committed by teamcity
parent 96d1f89836
commit de9d1dc536
9 changed files with 818 additions and 0 deletions
@@ -0,0 +1,72 @@
KtFile: untilOperatorGenericsClash.kt
PACKAGE_DIRECTIVE
<empty list>
IMPORT_LIST
<empty list>
FUN
PsiElement(fun)('fun')
PsiWhiteSpace(' ')
PsiElement(IDENTIFIER)('main')
VALUE_PARAMETER_LIST
PsiElement(LPAR)('(')
PsiElement(RPAR)(')')
PsiWhiteSpace(' ')
BLOCK
PsiElement(LBRACE)('{')
PsiWhiteSpace('\n ')
PROPERTY
PsiElement(val)('val')
PsiWhiteSpace(' ')
PsiElement(IDENTIFIER)('x')
PsiElement(COLON)(':')
PsiWhiteSpace(' ')
TYPE_REFERENCE
PsiErrorElement:Type expected
PsiElement(RANGE_UNTIL)('..<')
PsiErrorElement:Unexpected tokens (use ';' to separate expressions on the same line)
PsiElement(IDENTIFIER)('Int')
PsiElement(GT)('>')
PsiWhiteSpace(' ')
PsiElement(EQ)('=')
PsiWhiteSpace(' ')
PsiElement(INTEGER_LITERAL)('1')
PsiWhiteSpace('\n ')
PROPERTY
PsiElement(val)('val')
PsiWhiteSpace(' ')
PsiElement(IDENTIFIER)('x')
PsiWhiteSpace(' ')
PsiElement(EQ)('=')
PsiErrorElement:Expecting an expression
<empty list>
PsiWhiteSpace(' ')
PsiErrorElement:Unexpected tokens (use ';' to separate expressions on the same line)
PsiElement(RANGE_UNTIL)('..<')
PsiElement(IDENTIFIER)('Int')
PsiElement(GT)('>')
PsiElement(COLONCOLON)('::')
PsiElement(class)('class')
PsiWhiteSpace('\n ')
PROPERTY
PsiElement(val)('val')
PsiWhiteSpace(' ')
PsiElement(IDENTIFIER)('x')
PsiWhiteSpace(' ')
PsiElement(EQ)('=')
PsiWhiteSpace(' ')
CLASS_LITERAL_EXPRESSION
CALL_EXPRESSION
REFERENCE_EXPRESSION
PsiElement(IDENTIFIER)('`..`')
TYPE_ARGUMENT_LIST
PsiElement(LT)('<')
TYPE_PROJECTION
TYPE_REFERENCE
USER_TYPE
REFERENCE_EXPRESSION
PsiElement(IDENTIFIER)('Int')
PsiElement(GT)('>')
PsiElement(COLONCOLON)('::')
PsiElement(class)('class')
PsiWhiteSpace('\n')
PsiElement(RBRACE)('}')