Files
kotlin-fork/compiler/testData/codegen/box/unaryOp/longOverflow.kt
T
2018-06-09 19:15:38 +03:00

6 lines
222 B
Kotlin
Vendored

// IGNORE_BACKEND: JS_IR
fun box(): String {
val a: Long = -(1 shl 31)
if (a != -2147483648L) return "fail: in this case we should add to ints and than cast the result to long - overflow expected"
return "OK"
}