mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-09 00:21:47 +00:00
17 lines
314 B
Kotlin
Vendored
17 lines
314 B
Kotlin
Vendored
// !LANGUAGE: +InlineClasses
|
|
// WITH_RUNTIME
|
|
// IGNORE_BACKEND: JVM_IR
|
|
// IGNORE_BACKEND: JS_IR
|
|
|
|
inline class Foo(val arg: String)
|
|
|
|
fun box(): String {
|
|
val ls = listOf(Foo("abc"), Foo("def"))
|
|
var res = ""
|
|
for (el in ls) {
|
|
res += el.arg
|
|
}
|
|
|
|
return if (res != "abcdef") "Fail" else "OK"
|
|
}
|