mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-09 00:21:47 +00:00
See KT-36812. Aside from the problem stated there, D8 will throw out the entire LVT if it sees a variable that has not been written to (and will generate incorrect SSA if the slot is reused with a different type). Note: this only fixes a FIR test because it's missing an `else -> throw` branch, and default initialization satisfies the verifier and masks the incorrect control flow.
22 lines
359 B
Kotlin
Vendored
22 lines
359 B
Kotlin
Vendored
fun test(): Char {
|
|
val c: Char
|
|
val l = Any()
|
|
val l1 = Any()
|
|
val l2 = Any()
|
|
val l3 = Any()
|
|
val l4 = Any()
|
|
val l5 = Any()
|
|
val l6 = Any()
|
|
val l7 = Any()
|
|
val l8 = Any()
|
|
val l11 = Any()
|
|
val l12 = Any()
|
|
val l13 = Any()
|
|
val l14 = Any()
|
|
c = '1'
|
|
return c
|
|
}
|
|
|
|
// 2 ISTORE 0
|
|
// 1 LOCALVARIABLE c C L1 L16 0
|