Fix boxing/unboxing for generic functions on index expressions

Unsubstituted type should be used for coercion to box value of
 inline class type if it's needed. For the substituted value it's not
 known if it was a generic parameter or not.

 #KT-27502 Fixed
This commit is contained in:
Mikhail Zarechenskiy
2018-10-11 11:02:00 +03:00
parent 882a12d916
commit a8abd8cceb
8 changed files with 50 additions and 13 deletions
@@ -11984,6 +11984,11 @@ public class BlackBoxCodegenTestGenerated extends AbstractBlackBoxCodegenTest {
runTest("compiler/testData/codegen/box/inlineClasses/unboxValueFromPlatformType.kt");
}
@TestMetadata("unboxValueOfAnyBeforeMethodInvocation.kt")
public void testUnboxValueOfAnyBeforeMethodInvocation() throws Exception {
runTest("compiler/testData/codegen/box/inlineClasses/unboxValueOfAnyBeforeMethodInvocation.kt");
}
@TestMetadata("useInlineClassesInsideElvisOperator.kt")
public void testUseInlineClassesInsideElvisOperator() throws Exception {
runTest("compiler/testData/codegen/box/inlineClasses/useInlineClassesInsideElvisOperator.kt");