JVM_IR: IC: Unbox inline class argument of callable reference
if it is unbound and the underlying type is reference type. If the underlying type is primitive, it is boxed and unboxed correctly, otherwise, it is simply casted and not unboxed. Additionally, generate functions for inliner with inline classes in signature, so unboxing works. The unboxing is removed after inlining. #KT-44722 Fixed
This commit is contained in:
Vendored
+2
-2
@@ -54,11 +54,11 @@ fun box(): String {
|
||||
val a = IcAny(5)
|
||||
val o = IcOverIc(IcLong(6))
|
||||
|
||||
if (testUnboxed(i, l, a, o) != "345IcLong(l=6)") return "Fail 1"
|
||||
if (testUnboxed(i, l, a, o) != "345IcLong(l=6)") return "Fail 1 ${testUnboxed(i, l, a, o)}"
|
||||
if (testBoxed(i, l, a, o) != "345IcLong(l=6)") return "Fail 2"
|
||||
if (testLocalVars() != "012IcLong(l=3)") return "Fail 3"
|
||||
if (testGlobalProperties() != "123IcLong(l=4)") return "Fail 4"
|
||||
if (testCapturedVars() != "234IcLong(l=5)") return "Fail 5"
|
||||
if (testCapturedVars() != "234IcLong(l=5)") return "Fail 5 ${testCapturedVars()}"
|
||||
|
||||
return "OK"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user