[JVM] Support Enum.entries for enums being compiled with Kotlin 1.8+

#KT-53236
This commit is contained in:
Vsevolod Tolstopyatov
2022-07-21 10:54:28 +02:00
committed by Space
parent 1b6a43ba69
commit e708809e55
13 changed files with 328 additions and 16 deletions
@@ -0,0 +1,26 @@
// TARGET_BACKEND: JVM_IR
// WITH_RUNTIME
// !LANGUAGE: +EnumEntries
enum class SimpleEnum {
A, B, C
}
enum class WithConstructor(val x: String) {
A("1"), B("2"), C("3")
}
enum class WithEntryClass {
A {
override fun foo() {}
}
;
abstract fun foo()
}
annotation class Ann
enum class WithAnnotations {
@Ann A, @Ann B
}