[FE] Check types in canHaveCommonSubtype for intersection emptiness with erasing nullability

It doesn't affect having common subtypes check but may lead to false positives

^KT-52364 Fixed
This commit is contained in:
Victor Petukhov
2022-05-12 14:57:21 +02:00
committed by teamcity
parent ba158de848
commit 11eb5ce39c
7 changed files with 68 additions and 4 deletions
@@ -15523,6 +15523,12 @@ public class DiagnosisCompilerTestFE10TestdataTestGenerated extends AbstractDiag
runTest("compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt51016.kt");
}
@Test
@TestMetadata("kt52364.kt")
public void testKt52364() throws Exception {
runTest("compiler/testData/diagnostics/tests/inference/emptyIntersectionTypes/kt52364.kt");
}
@Test
@TestMetadata("nullableEmptyIntersection.kt")
public void testNullableEmptyIntersection() throws Exception {