Files
kotlin-fork/compiler/testData/ir/irText/expressions/coercionToUnit.fir.kt.txt
T
Denis.Zharkov 1e0d9f4075 FIR2IR: Do not add implicit casts for types with different nullability
For smart casts, elvises, etc., there are no implicit casts in psi2fir
in changed test data
2021-01-29 10:50:22 +03:00

28 lines
618 B
Plaintext
Vendored

val test1: Function0<Unit>
field = local fun <anonymous>(): Int {
42 /*~> Unit */
}
get
fun test2(mc: MutableCollection<String>) {
mc.add(element = "") /*~> Unit */
}
fun test3() {
{ // BLOCK
val tmp0_safe_receiver: PrintStream? = #out
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
else -> tmp0_safe_receiver.println(p0 = "Hello,")
}
} /*~> Unit */
{ // BLOCK
val tmp1_safe_receiver: PrintStream? = #out
when {
EQEQ(arg0 = tmp1_safe_receiver, arg1 = null) -> null
else -> tmp1_safe_receiver.println(p0 = "world!")
}
} /*~> Unit */
}