Minor. Add tests and comment about copying generic parameters to
constructor, but not function reference to the constructor. #KT-32162
This commit is contained in:
+13
@@ -0,0 +1,13 @@
|
||||
// CHECK_BYTECODE_LISTING
|
||||
// LANGUAGE: -JvmInlineValueClasses, +GenericInlineClassParameter
|
||||
// IGNORE_BACKEND: JVM
|
||||
|
||||
inline class ICStr(val value: String)
|
||||
inline class ICIStr<T : ICStr>(val value: T)
|
||||
inline class ICIStrArray<T : ICStr>(val value: Array<T>)
|
||||
|
||||
fun box(): String {
|
||||
val res = ICIStrArray(arrayOf(ICStr("OK"))).value[0].value
|
||||
if (res != "OK") return res
|
||||
return ICIStr(ICStr("OK")).value.value
|
||||
}
|
||||
Reference in New Issue
Block a user