mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Coin's diamond parsing test
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
PsiJavaFile:New16.java
|
||||
PsiNewExpression:new C<>()
|
||||
PsiKeyword:new('new')
|
||||
PsiReferenceParameterList
|
||||
<empty list>
|
||||
PsiWhiteSpace(' ')
|
||||
PsiJavaCodeReferenceElement:C<>
|
||||
PsiIdentifier:C('C')
|
||||
PsiReferenceParameterList
|
||||
PsiJavaToken:LT('<')
|
||||
PsiTypeElement:
|
||||
PsiTypeElement:DIAMOND
|
||||
<empty list>
|
||||
PsiJavaToken:GT('>')
|
||||
PsiExpressionList
|
||||
PsiJavaToken:LPARENTH('(')
|
||||
PsiJavaToken:RPARENTH(')')
|
||||
+5
@@ -18,6 +18,7 @@ package com.intellij.lang.java.parser.partial;
|
||||
import com.intellij.lang.PsiBuilder;
|
||||
import com.intellij.lang.java.parser.ExpressionParser;
|
||||
import com.intellij.lang.java.parser.JavaParsingTestCase;
|
||||
import com.intellij.pom.java.LanguageLevel;
|
||||
|
||||
|
||||
public class ExpressionParserTest extends JavaParsingTestCase {
|
||||
@@ -73,6 +74,10 @@ public class ExpressionParserTest extends JavaParsingTestCase {
|
||||
public void testNew13() { doParserTest("new int[1][][2]"); }
|
||||
public void testNew14() { doParserTest("Q.new A()"); }
|
||||
public void testNew15() { doParserTest("new C<?>.B()"); }
|
||||
public void testNew16() {
|
||||
withLevel(LanguageLevel.JDK_1_7,
|
||||
new Runnable() { public void run() { doParserTest("new C<>()"); } });
|
||||
}
|
||||
|
||||
public void testExprList0() { doParserTest("f(1,2)"); }
|
||||
public void testExprList1() { doParserTest("f("); }
|
||||
|
||||
Reference in New Issue
Block a user