Fixed the /**/ case. It is now a comment

This commit is contained in:
Andrey Breslav
2012-03-23 09:46:09 +01:00
parent 73baa8b65d
commit 77159a0d8e
4 changed files with 456 additions and 428 deletions
@@ -164,6 +164,10 @@ LONG_TEMPLATE_ENTRY_END=\}
// (Nested) comments
"/**/" {
return JetTokens.BLOCK_COMMENT;
}
"/**" {
pushState(DOC_COMMENT);
commentDepth = 0;
File diff suppressed because it is too large Load Diff
+2 -2
View File
@@ -10,10 +10,10 @@ b
b
/***/
b
/**/***/*/
/** /***/*/
b
/** /**
*/***/
b
}
}
+21 -5
View File
@@ -17,11 +17,27 @@ JetFile: NestedComments.jet
REFERENCE_EXPRESSION
PsiElement(IDENTIFIER)('b')
PsiWhiteSpace('\n')
PsiComment(DOC_COMMENT)('/**/\nb\n/* */\nb\n/*/**/*/\nb\n/***/\nb\n/**/***/')
PsiErrorElement:Expecting an element
PsiElement(MUL)('*')
PsiErrorElement:Unexpected tokens (use ';' to separate expressions on the same line)
PsiElement(DIV)('/')
PsiComment(BLOCK_COMMENT)('/**/')
PsiWhiteSpace('\n')
REFERENCE_EXPRESSION
PsiElement(IDENTIFIER)('b')
PsiWhiteSpace('\n')
PsiComment(BLOCK_COMMENT)('/* */')
PsiWhiteSpace('\n')
REFERENCE_EXPRESSION
PsiElement(IDENTIFIER)('b')
PsiWhiteSpace('\n')
PsiComment(BLOCK_COMMENT)('/*/**/*/')
PsiWhiteSpace('\n')
REFERENCE_EXPRESSION
PsiElement(IDENTIFIER)('b')
PsiWhiteSpace('\n')
PsiComment(DOC_COMMENT)('/***/')
PsiWhiteSpace('\n')
REFERENCE_EXPRESSION
PsiElement(IDENTIFIER)('b')
PsiWhiteSpace('\n')
PsiComment(DOC_COMMENT)('/** /***/*/')
PsiWhiteSpace('\n')
REFERENCE_EXPRESSION
PsiElement(IDENTIFIER)('b')