K2: Support inference case with a mix of smart-cast and expected type
The idea is that we should not fix (i.e. choose any of the fork branches) on the stage of candidate processing before completion, but it's enough just to check that current state can be converged to success. And when completion starts, and we add expected type to the system, we've got more information to choose the correct fork branch. NB: The old `processForkConstraints` is being called just at the beginning of the completion phase. ^KT-43296 In Progress
This commit is contained in:
committed by
Space Team
parent
77e197d46a
commit
715a73c8fb
+6
@@ -14276,6 +14276,12 @@ public class DiagnosisCompilerTestFE10TestdataTestGenerated extends AbstractDiag
|
||||
runTest("compiler/testData/diagnostics/tests/inference/smartCastFork.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("smartCastForkForExpectType.kt")
|
||||
public void testSmartCastForkForExpectType() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/tests/inference/smartCastForkForExpectType.kt");
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("specialCallsWithCallableReferences.kt")
|
||||
public void testSpecialCallsWithCallableReferences() throws Exception {
|
||||
|
||||
Reference in New Issue
Block a user