mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-08 15:53:19 +00:00
25 lines
441 B
Kotlin
Vendored
25 lines
441 B
Kotlin
Vendored
// IGNORE_BACKEND_FIR: JVM_IR
|
|
interface IFoo {
|
|
fun foo(): String
|
|
}
|
|
|
|
interface IBar {
|
|
fun bar(): String
|
|
}
|
|
|
|
enum class Test : IFoo, IBar {
|
|
FOO {
|
|
// FOO referenced from inner class constructor with initialized 'this'
|
|
inner class Inner {
|
|
val fooFoo = FOO.foo()
|
|
}
|
|
|
|
val z = Inner()
|
|
|
|
override fun foo() = "OK"
|
|
|
|
override fun bar() = z.fooFoo
|
|
}
|
|
}
|
|
|
|
fun box() = Test.FOO.bar() |