Files
kotlin-fork/backend.native/tests/external/codegen/blackbox/operatorConventions/percentAsModOnBigIntegerWithoutRem.kt
T
Ilya Matveev 1b553ebfaf backend/tests: Add blackbox tests from Kotlin JVM
Added tests from testData/codegen/box directory. There are blackbox tests
in other directories and they are to be added.
2017-01-20 14:04:04 +03:00

11 lines
271 B
Kotlin

// TARGET_BACKEND: JVM
// LANGUAGE_VERSION: 1.0
// FULL_JDK
import java.math.BigInteger
fun box(): String {
val m = BigInteger.valueOf(-2) % BigInteger.valueOf(3)
return if (m != BigInteger.valueOf(1)) "Fail: BigInteger(-2) mod BigInteger(3) == $m" else "OK"
}