mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-10 15:53:46 +00:00
14 lines
205 B
Kotlin
Vendored
14 lines
205 B
Kotlin
Vendored
// !LANGUAGE: +InlineClasses
|
|
|
|
interface A {
|
|
fun f(x: String) = x
|
|
}
|
|
|
|
inline class B(val y: String) : A {
|
|
override fun f(x: String) = super.f(x + y)
|
|
}
|
|
|
|
fun box(): String {
|
|
return B("K").f("O")
|
|
}
|