Files
kotlin-fork/compiler/testData/ir/irText/expressions/temporaryInEnumEntryInitializer.fir.kt.txt
T
Alexander Udalov 68b94b07b8 Fir2Ir: more precise calculation of enum class modality
Use the same condition as in the already existing `createIrEnumEntry`
function (and as in psi2ir): enum class should be final unless there's
an enum entry with any declaration other than its constructor.

 #KT-57216
2023-04-27 11:02:22 +00:00

33 lines
635 B
Kotlin
Vendored

val n: Any?
field = null
get
enum class En : Enum<En> {
private constructor(x: String?) /* primary */ {
super/*Enum*/<En>()
/* <init>() */
}
val x: String?
field = x
get
ENTRY = En(x = { // BLOCK
val tmp0_safe_receiver: Any? = <get-n>()
when {
EQEQ(arg0 = tmp0_safe_receiver, arg1 = null) -> null
else -> tmp0_safe_receiver.toString()
}
})
fun values(): Array<En> /* Synthetic body for ENUM_VALUES */
fun valueOf(value: String): En /* Synthetic body for ENUM_VALUEOF */
val entries: EnumEntries<En>
get(): EnumEntries<En> /* Synthetic body for ENUM_ENTRIES */
}