fa4a4e56f3
Signed-off-by: Evgeniy.Zhelenskiy <Evgeniy.Zhelenskiy@jetbrains.com> #KT-1179
16 lines
302 B
Kotlin
Vendored
16 lines
302 B
Kotlin
Vendored
// WITH_STDLIB
|
|
// TARGET_BACKEND: JVM_IR
|
|
// LANGUAGE: +ValueClasses
|
|
|
|
@JvmInline
|
|
value class DPoint(val x: Double, val y: Double)
|
|
|
|
fun box(): String {
|
|
var res = 0.0
|
|
for (x in listOf(DPoint(1.0, 2.0), DPoint(3.0, 4.0))) {
|
|
res += x.x + x.y
|
|
}
|
|
require(res == 10.0)
|
|
return "OK"
|
|
}
|