JVM_IR: fix lifting of arguments to object super constructors

If the arguments are reordered, they can not only be reads of temporary
variables, but also implicit type casts of said reads.

Fixes #KT-42002
This commit is contained in:
pyos
2020-09-21 13:33:42 +02:00
committed by max-kammerer
parent 4d5e54cab6
commit 5954db18cb
6 changed files with 45 additions and 8 deletions
@@ -315,6 +315,11 @@ public class BlackBoxCodegenTestGenerated extends AbstractBlackBoxCodegenTest {
runTest("compiler/testData/codegen/box/argumentOrder/argumentOrderInObjectSuperCall.kt");
}
@TestMetadata("argumentOrderInObjectSuperCallWithPlatformType.kt")
public void testArgumentOrderInObjectSuperCallWithPlatformType() throws Exception {
runTest("compiler/testData/codegen/box/argumentOrder/argumentOrderInObjectSuperCallWithPlatformType.kt");
}
@TestMetadata("argumentOrderInSuperCall.kt")
public void testArgumentOrderInSuperCall() throws Exception {
runTest("compiler/testData/codegen/box/argumentOrder/argumentOrderInSuperCall.kt");