Files
Alexander Udalov b3820564b0 Kapt: never generate enums as final
Behavior differs between JVM and JVM_IR backends here because in JVM,
the class descriptor comes from the frontend, and its modality for enum
is never final. For JVM IR, the class descriptor is based on IrClass,
whose modality is sometimes final for enum, presumably because it's
easier for backends (see `ClassGenerator.getEffectiveModality`).

 #KT-49682
2022-02-08 20:15:14 +01:00

16 lines
296 B
Kotlin
Vendored

// STRIP_METADATA
interface Context
enum class Result {
SUCCESS, ERROR
}
abstract class BaseClass(context: Context, num: Int, bool: Boolean) {
abstract fun doJob(): Result
}
class Inheritor(context: Context) : BaseClass(context, 5, true) {
override fun doJob() = Result.SUCCESS
}