Add regression test for already fixed issue KT-41885

This commit is contained in:
Victor Petukhov
2020-09-15 19:02:33 +03:00
parent 7c360c0068
commit 8cabfda832
5 changed files with 39 additions and 0 deletions
@@ -3200,6 +3200,11 @@ public class FirOldFrontendDiagnosticsTestWithStdlibGenerated extends AbstractFi
runTest("compiler/testData/diagnostics/testsWithStdLib/inference/completion/postponedArgumentsAnalysis/kt38799.kt");
}
@TestMetadata("manyArguments.kt")
public void testManyArguments() throws Exception {
runTest("compiler/testData/diagnostics/testsWithStdLib/inference/completion/postponedArgumentsAnalysis/manyArguments.kt");
}
@TestMetadata("moreSpecificOutputType.kt")
public void testMoreSpecificOutputType() throws Exception {
runTest("compiler/testData/diagnostics/testsWithStdLib/inference/completion/postponedArgumentsAnalysis/moreSpecificOutputType.kt");
@@ -0,0 +1,21 @@
// FIR_IDENTICAL
// !DIAGNOSTICS: -UNUSED_VARIABLE
fun main() {
val list: List<Int.() -> Unit> = listOf({}, {}, {}, {}, {}, {}, {}, {}, {}, {}, {}, {})
val map: Map<Int, Int.() -> Unit> = mapOf(
1 to {},
2 to {},
3 to {},
4 to {},
5 to {},
6 to {},
7 to {},
8 to {},
9 to {},
10 to {},
11 to {},
12 to {}
)
}
@@ -0,0 +1,3 @@
package
public fun main(): kotlin.Unit
@@ -3350,6 +3350,11 @@ public class DiagnosticsTestWithStdLibGenerated extends AbstractDiagnosticsTestW
runTest("compiler/testData/diagnostics/testsWithStdLib/inference/completion/postponedArgumentsAnalysis/kt38799.kt");
}
@TestMetadata("manyArguments.kt")
public void testManyArguments() throws Exception {
runTest("compiler/testData/diagnostics/testsWithStdLib/inference/completion/postponedArgumentsAnalysis/manyArguments.kt");
}
@TestMetadata("moreSpecificOutputType.kt")
public void testMoreSpecificOutputType() throws Exception {
runTest("compiler/testData/diagnostics/testsWithStdLib/inference/completion/postponedArgumentsAnalysis/moreSpecificOutputType.kt");
@@ -3350,6 +3350,11 @@ public class DiagnosticsTestWithStdLibUsingJavacGenerated extends AbstractDiagno
runTest("compiler/testData/diagnostics/testsWithStdLib/inference/completion/postponedArgumentsAnalysis/kt38799.kt");
}
@TestMetadata("manyArguments.kt")
public void testManyArguments() throws Exception {
runTest("compiler/testData/diagnostics/testsWithStdLib/inference/completion/postponedArgumentsAnalysis/manyArguments.kt");
}
@TestMetadata("moreSpecificOutputType.kt")
public void testMoreSpecificOutputType() throws Exception {
runTest("compiler/testData/diagnostics/testsWithStdLib/inference/completion/postponedArgumentsAnalysis/moreSpecificOutputType.kt");