2d4ad5e408
enum geneneration is partially covered in regression tests, it is not very convenient
13 lines
167 B
Kotlin
13 lines
167 B
Kotlin
enum class Season {
|
|
WINTER
|
|
SPRING
|
|
SUMMER
|
|
AUTUMN
|
|
}
|
|
|
|
fun foo(): Season = Season.SPRING
|
|
|
|
fun box() =
|
|
if (foo() == Season.SPRING) "OK"
|
|
else "fail"
|