JVM_IR: use nullability when boxing/unboxing inline class types
Given inline class V(Any?), a coercion from (Object, V) to (Object, V?) is boxing. In theory, the same issue in the old backend can be fixed by making `KotlinTypeMapper.mapUnderlyingTypeOfInlineClassType` use `computeExpandedTypeForInlineClass`, but for some reason this breaks a lot of stuff. #KT-48430 Fixed
This commit is contained in:
+5
@@ -15222,6 +15222,11 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
|||||||
runTest("compiler/testData/codegen/box/inlineClasses/boxImplDoesNotExecuteInitBlock.kt");
|
runTest("compiler/testData/codegen/box/inlineClasses/boxImplDoesNotExecuteInitBlock.kt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("boxNullableForFakeOverride.kt")
|
||||||
|
public void testBoxNullableForFakeOverride() throws Exception {
|
||||||
|
runTest("compiler/testData/codegen/box/inlineClasses/boxNullableForFakeOverride.kt");
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("boxNullableValueOfInlineClassWithNonNullUnderlyingType.kt")
|
@TestMetadata("boxNullableValueOfInlineClassWithNonNullUnderlyingType.kt")
|
||||||
public void testBoxNullableValueOfInlineClassWithNonNullUnderlyingType() throws Exception {
|
public void testBoxNullableValueOfInlineClassWithNonNullUnderlyingType() throws Exception {
|
||||||
runTest("compiler/testData/codegen/box/inlineClasses/boxNullableValueOfInlineClassWithNonNullUnderlyingType.kt");
|
runTest("compiler/testData/codegen/box/inlineClasses/boxNullableValueOfInlineClassWithNonNullUnderlyingType.kt");
|
||||||
|
|||||||
Reference in New Issue
Block a user