Files
kotlin-fork/compiler/testData/ir/irText/expressions/primitivesImplicitConversions.kt.txt
T
Dmitriy Novozhilov b454fcc1e0 [FIR] Save IR dumps to .ir.txt files instead of .txt in tests
This is needed to avoid clashes between different dumps from different
  handlers
2021-10-12 17:26:36 +03:00

50 lines
675 B
Kotlin
Vendored

val test1: Long
field = 42L
get
val test2: Short
field = 42S
get
val test3: Byte
field = 42B
get
val test4: Long
field = -42L
get
val test5: Short
field = -42S
get
val test6: Byte
field = -42B
get
fun test() {
val test1: Int? = 42
val test2: Long = 42L
val test3: Long? = 42L
val test4: Long? = -1L
val test5: Long? = 1.unaryMinus()
val test6: Short? = 1.unaryMinus()
val test7: Byte? = 1.unaryMinus()
}
fun testImplicitArguments(x: Long = 1.unaryMinus()) {
}
class TestImplicitArguments {
constructor(x: Long = 1.unaryMinus()) /* primary */ {
super/*Any*/()
/* <init>() */
}
val x: Long
field = x
get
}