[NI] Fix trace manipulations for builder inference and ::-expressions

For a class literal Type::class we are resolving Type as a constructor,
 getting all diagnostics (about missing arguments, for example) and then
 just not committing this trace with errors

 #KT-37626 Fixed
This commit is contained in:
Mikhail Zarechenskiy
2020-03-24 02:44:00 +03:00
parent 6213680604
commit 38a719cb22
13 changed files with 181 additions and 4 deletions
@@ -1922,6 +1922,11 @@ public class DiagnosticsTestWithStdLibGenerated extends AbstractDiagnosticsTestW
runTest("compiler/testData/diagnostics/testsWithStdLib/coroutines/inference/correctMember.kt");
}
@TestMetadata("doubleColonExpressionToClassWithParameters.kt")
public void testDoubleColonExpressionToClassWithParameters() throws Exception {
runTest("compiler/testData/diagnostics/testsWithStdLib/coroutines/inference/doubleColonExpressionToClassWithParameters.kt");
}
@TestMetadata("elvisOperatorAgainstFlexibleType.kt")
public void testElvisOperatorAgainstFlexibleType() throws Exception {
runTest("compiler/testData/diagnostics/testsWithStdLib/coroutines/inference/elvisOperatorAgainstFlexibleType.kt");
@@ -1922,6 +1922,11 @@ public class DiagnosticsTestWithStdLibUsingJavacGenerated extends AbstractDiagno
runTest("compiler/testData/diagnostics/testsWithStdLib/coroutines/inference/correctMember.kt");
}
@TestMetadata("doubleColonExpressionToClassWithParameters.kt")
public void testDoubleColonExpressionToClassWithParameters() throws Exception {
runTest("compiler/testData/diagnostics/testsWithStdLib/coroutines/inference/doubleColonExpressionToClassWithParameters.kt");
}
@TestMetadata("elvisOperatorAgainstFlexibleType.kt")
public void testElvisOperatorAgainstFlexibleType() throws Exception {
runTest("compiler/testData/diagnostics/testsWithStdLib/coroutines/inference/elvisOperatorAgainstFlexibleType.kt");
@@ -6260,6 +6260,11 @@ public class BlackBoxCodegenTestGenerated extends AbstractBlackBoxCodegenTest {
runTestWithPackageReplacement("compiler/testData/codegen/box/coroutines/dispatchResume.kt", "kotlin.coroutines");
}
@TestMetadata("doubleColonExpressionsGenerationInBuilderInference.kt")
public void testDoubleColonExpressionsGenerationInBuilderInference() throws Exception {
runTest("compiler/testData/codegen/box/coroutines/doubleColonExpressionsGenerationInBuilderInference.kt");
}
@TestMetadata("emptyClosure.kt")
public void testEmptyClosure_1_2() throws Exception {
runTestWithPackageReplacement("compiler/testData/codegen/box/coroutines/emptyClosure.kt", "kotlin.coroutines.experimental");
@@ -6260,6 +6260,11 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
runTestWithPackageReplacement("compiler/testData/codegen/box/coroutines/dispatchResume.kt", "kotlin.coroutines");
}
@TestMetadata("doubleColonExpressionsGenerationInBuilderInference.kt")
public void testDoubleColonExpressionsGenerationInBuilderInference() throws Exception {
runTest("compiler/testData/codegen/box/coroutines/doubleColonExpressionsGenerationInBuilderInference.kt");
}
@TestMetadata("emptyClosure.kt")
public void testEmptyClosure_1_2() throws Exception {
runTestWithPackageReplacement("compiler/testData/codegen/box/coroutines/emptyClosure.kt", "kotlin.coroutines.experimental");
@@ -6140,6 +6140,11 @@ public class IrBlackBoxCodegenTestGenerated extends AbstractIrBlackBoxCodegenTes
runTestWithPackageReplacement("compiler/testData/codegen/box/coroutines/dispatchResume.kt", "kotlin.coroutines");
}
@TestMetadata("doubleColonExpressionsGenerationInBuilderInference.kt")
public void testDoubleColonExpressionsGenerationInBuilderInference() throws Exception {
runTest("compiler/testData/codegen/box/coroutines/doubleColonExpressionsGenerationInBuilderInference.kt");
}
@TestMetadata("emptyClosure.kt")
public void testEmptyClosure_1_3() throws Exception {
runTestWithPackageReplacement("compiler/testData/codegen/box/coroutines/emptyClosure.kt", "kotlin.coroutines");