[JVM_IR] Use ifne and ifeq for integer zero comparisons.

This commit is contained in:
Mads Ager
2020-04-23 14:23:40 +02:00
committed by max-kammerer
parent e8a6ddceaa
commit fed6272de4
4 changed files with 26 additions and 9 deletions
@@ -1,6 +1,3 @@
// IGNORE_BACKEND: JVM_IR
// TODO KT-36841 Generate integer comparison with 0 instructions (IFNE, etc) when comparing integers with 0 in JVM_IR
fun test(a: Int, b: Int, c: Int) {
when (0) {
a -> throw IllegalArgumentException("a is 0")