PSI2IR: Infer smart cast on dispatch receiver of FAKE_OVERRIDE calls

NB here we have use derived class type with type arguments replaced
with star-projections. This emulates JVM erasure (to some degree),
but, unfortunately, that's best we can offer here at the moment.
This commit is contained in:
Dmitry Petrov
2019-12-18 16:04:11 +03:00
parent feda832eb7
commit 09c3279cc7
8 changed files with 493 additions and 8 deletions
@@ -1740,6 +1740,11 @@ public class IrTextTestCaseGenerated extends AbstractIrTextTestCase {
runTest("compiler/testData/ir/irText/types/platformTypeReceiver.kt");
}
@TestMetadata("smartCastOnFakeOverrideReceiver.kt")
public void testSmartCastOnFakeOverrideReceiver() throws Exception {
runTest("compiler/testData/ir/irText/types/smartCastOnFakeOverrideReceiver.kt");
}
@TestMetadata("smartCastOnFieldReceiverOfGenericType.kt")
public void testSmartCastOnFieldReceiverOfGenericType() throws Exception {
runTest("compiler/testData/ir/irText/types/smartCastOnFieldReceiverOfGenericType.kt");