Files
kotlin/compiler/testData/codegen/bytecodeText/inlineClasses/hashCodeIsCalledByInlineClass.kt
Dmitry Petrov 80a67477db Generate method calls for inline classes through IC, not IC$Erased
IC extends IC$Erased, so it should be fine.
2018-09-05 12:20:57 +03:00

14 lines
286 B
Kotlin
Vendored

// !LANGUAGE: +InlineClasses
// FILE: Z.kt
inline class Z(val x: Int)
// FILE: Test.kt
fun testZ(z: Z) = z.hashCode()
fun testNZ(z: Z?) = z?.hashCode()
// @TestKt.class:
// 0 INVOKESTATIC Z\$Erased\.hashCode
// 0 INVOKESTATIC Z\-Erased\.hashCode
// 2 INVOKESTATIC Z\.hashCode \(I\)I