KT-35811: Type parameter angle brackets followed by equal sign are parsed incorrectly if whitespace is missing

This commit is contained in:
Iven Krall
2022-03-26 18:40:15 +01:00
committed by teamcity
parent 8de4eb798c
commit ba5c85d6f2
21 changed files with 705 additions and 382 deletions
@@ -10655,6 +10655,28 @@ public class DiagnosisCompilerTestFE10TestdataTestGenerated extends AbstractDiag
}
}
@Nested
@TestMetadata("compiler/testData/diagnostics/tests/expressionAfterTypeReference")
@TestDataPath("$PROJECT_ROOT")
public class ExpressionAfterTypeReference {
@Test
public void testAllFilesPresentInExpressionAfterTypeReference() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/tests/expressionAfterTypeReference"), Pattern.compile("^(.+)\\.kt$"), Pattern.compile("^(.+)\\.fir\\.kts?$"), true);
}
@Test
@TestMetadata("allowExpressionAfterTypeReference.kt")
public void testAllowExpressionAfterTypeReference() throws Exception {
runTest("compiler/testData/diagnostics/tests/expressionAfterTypeReference/allowExpressionAfterTypeReference.kt");
}
@Test
@TestMetadata("forbidExpressionAfterTypeReference.kt")
public void testForbidExpressionAfterTypeReference() throws Exception {
runTest("compiler/testData/diagnostics/tests/expressionAfterTypeReference/forbidExpressionAfterTypeReference.kt");
}
}
@Nested
@TestMetadata("compiler/testData/diagnostics/tests/extensions")
@TestDataPath("$PROJECT_ROOT")