FIR: Support FirComparisonOperator in Fir2Ir

^KT-31163 Fixed
This commit is contained in:
Denis Zharkov
2020-02-27 12:37:49 +03:00
parent 434444cd69
commit 8fca343ef0
26 changed files with 292 additions and 84 deletions
+1 -2
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
operator fun Int.compareTo(c: Char) = 0
fun foo(x: Int, y: Char): String {
@@ -10,4 +9,4 @@ fun foo(x: Int, y: Char): String {
fun box(): String {
return foo(42, 'O')
}
}
@@ -1,5 +1,4 @@
// !LANGUAGE: +ProperIeee754Comparisons
// IGNORE_BACKEND_FIR: JVM_IR
operator fun Int.compareTo(c: Char) = 0
fun foo(x: Int, y: Char): String {
@@ -11,4 +10,4 @@ fun foo(x: Int, y: Char): String {
fun box(): String {
return foo(42, 'O')
}
}
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
inline fun ltx(a: Comparable<Any>, b: Any) = a < b
inline fun lex(a: Comparable<Any>, b: Any) = a <= b
inline fun gex(a: Comparable<Any>, b: Any) = a >= b
@@ -44,4 +43,4 @@ fun box(): String {
else -> "OK"
}
}
}
@@ -1,5 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
inline fun ltx(a: Comparable<Any>, b: Any) = a < b
inline fun lex(a: Comparable<Any>, b: Any) = a <= b
inline fun gex(a: Comparable<Any>, b: Any) = a >= b
@@ -79,4 +77,4 @@ fun box(): String {
else -> "OK"
}
}
}
+1 -2
View File
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
class KeySpan(val left: String) {
public fun matches(value : String) : Boolean {
@@ -11,4 +10,4 @@ class KeySpan(val left: String) {
fun box() : String {
KeySpan("1").matches("3")
return "OK"
}
}
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
class C
operator fun C.compareTo(o: C) : Int {
@@ -9,4 +8,4 @@ operator fun C.compareTo(o: C) : Int {
return -1
}
fun box() : String = if (C() > C()) "OK" else "FAIL"
fun box() : String = if (C() > C()) "OK" else "FAIL"
@@ -1,5 +1,4 @@
// !LANGUAGE: -ProperIeee754Comparisons
// IGNORE_BACKEND_FIR: JVM_IR
// IGNORE_BACKEND: NATIVE
// DONT_TARGET_EXACT_BACKEND: JS_IR
fun box(): String {
@@ -14,4 +13,4 @@ fun box(): String {
}
return "fail"
}
}
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
fun checkLess(x: Boolean, y: Boolean) = when {
x >= y -> "Fail $x >= $y"
!(x < y) -> "Fail !($x < $y)"
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
fun checkLess(x: Double, y: Int) = when {
x >= y -> "Fail $x >= $y"
!(x < y) -> "Fail !($x < $y)"
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
fun checkLess(x: Double, y: Long) = when {
x >= y -> "Fail $x >= $y"
!(x < y) -> "Fail !($x < $y)"
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
fun checkLess(x: Array<Int>, y: Array<Int>) = when {
x >= y -> "Fail $x >= $y"
!(x < y) -> "Fail !($x < $y)"
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
class A(val x: Int)
operator fun A.compareTo(other: A) = x.compareTo(other.x)
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
fun checkLess(x: Int, y: Double) = when {
x >= y -> "Fail $x >= $y"
!(x < y) -> "Fail !($x < $y)"
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
fun checkLess(x: Int, y: Long) = when {
x >= y -> "Fail $x >= $y"
!(x < y) -> "Fail !($x < $y)"
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
fun checkLess(x: Long, y: Double) = when {
x >= y -> "Fail $x >= $y"
!(x < y) -> "Fail !($x < $y)"
@@ -1,4 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
fun checkLess(x: Long, y: Int) = when {
x >= y -> "Fail $x >= $y"
!(x < y) -> "Fail !($x < $y)"
@@ -1,5 +1,3 @@
// IGNORE_BACKEND_FIR: JVM_IR
fun box(): String {
if (1 >= 1.9) return "Fail #1"
if (1.compareTo(1.1) >= 0) return "Fail #2"
@@ -39,25 +39,45 @@ FILE fqName:<root> fileName:/conventionComparisons.kt
VALUE_PARAMETER name:a2 index:1 type:<root>.IA
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun test1 (a1: <root>.IA, a2: <root>.IA): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: /IA' type=kotlin.Boolean
CALL 'public final fun greater (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=GT
arg0: CALL 'public abstract fun compareTo (other: <root>.IA): kotlin.Int [operator] declared in <root>.IB' type=kotlin.Int origin=null
$this: GET_VAR '<this>: <root>.IB declared in <root>.test1' type=<root>.IB origin=null
$receiver: GET_VAR 'a1: <root>.IA declared in <root>.test1' type=<root>.IA origin=null
other: GET_VAR 'a2: <root>.IA declared in <root>.test1' type=<root>.IA origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:test2 visibility:public modality:FINAL <> ($receiver:<root>.IB, a1:<root>.IA, a2:<root>.IA) returnType:kotlin.Boolean
$receiver: VALUE_PARAMETER name:<this> type:<root>.IB
VALUE_PARAMETER name:a1 index:0 type:<root>.IA
VALUE_PARAMETER name:a2 index:1 type:<root>.IA
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun test2 (a1: <root>.IA, a2: <root>.IA): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: /IA' type=kotlin.Boolean
CALL 'public final fun greaterOrEqual (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=GTEQ
arg0: CALL 'public abstract fun compareTo (other: <root>.IA): kotlin.Int [operator] declared in <root>.IB' type=kotlin.Int origin=null
$this: GET_VAR '<this>: <root>.IB declared in <root>.test2' type=<root>.IB origin=null
$receiver: GET_VAR 'a1: <root>.IA declared in <root>.test2' type=<root>.IA origin=null
other: GET_VAR 'a2: <root>.IA declared in <root>.test2' type=<root>.IA origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:test3 visibility:public modality:FINAL <> ($receiver:<root>.IB, a1:<root>.IA, a2:<root>.IA) returnType:kotlin.Boolean
$receiver: VALUE_PARAMETER name:<this> type:<root>.IB
VALUE_PARAMETER name:a1 index:0 type:<root>.IA
VALUE_PARAMETER name:a2 index:1 type:<root>.IA
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun test3 (a1: <root>.IA, a2: <root>.IA): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: /IA' type=kotlin.Boolean
CALL 'public final fun less (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=LT
arg0: CALL 'public abstract fun compareTo (other: <root>.IA): kotlin.Int [operator] declared in <root>.IB' type=kotlin.Int origin=null
$this: GET_VAR '<this>: <root>.IB declared in <root>.test3' type=<root>.IB origin=null
$receiver: GET_VAR 'a1: <root>.IA declared in <root>.test3' type=<root>.IA origin=null
other: GET_VAR 'a2: <root>.IA declared in <root>.test3' type=<root>.IA origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:test4 visibility:public modality:FINAL <> ($receiver:<root>.IB, a1:<root>.IA, a2:<root>.IA) returnType:kotlin.Boolean
$receiver: VALUE_PARAMETER name:<this> type:<root>.IB
VALUE_PARAMETER name:a1 index:0 type:<root>.IA
VALUE_PARAMETER name:a2 index:1 type:<root>.IA
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun test4 (a1: <root>.IA, a2: <root>.IA): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: /IA' type=kotlin.Boolean
CALL 'public final fun lessOrEqual (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=LTEQ
arg0: CALL 'public abstract fun compareTo (other: <root>.IA): kotlin.Int [operator] declared in <root>.IB' type=kotlin.Int origin=null
$this: GET_VAR '<this>: <root>.IB declared in <root>.test4' type=<root>.IB origin=null
$receiver: GET_VAR 'a1: <root>.IA declared in <root>.test4' type=<root>.IA origin=null
other: GET_VAR 'a2: <root>.IA declared in <root>.test4' type=<root>.IA origin=null
arg1: CONST Int type=kotlin.Int value=0
@@ -111,7 +111,13 @@ FILE fqName:<root> fileName:/floatingPointLess.kt
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
then: ERROR_CALL 'Comparison of arguments with different types: kotlin/Float, kotlin/Double' type=kotlin.Boolean
then: CALL 'public final fun less (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=LT
arg0: CALL 'public final fun compareTo (other: kotlin.Double): kotlin.Int [operator] declared in kotlin.Float' type=kotlin.Int origin=null
$this: TYPE_OP type=kotlin.Float origin=IMPLICIT_CAST typeOperand=kotlin.Float
GET_VAR 'x: kotlin.Any declared in <root>.testFD' type=kotlin.Any origin=null
other: TYPE_OP type=kotlin.Double origin=IMPLICIT_CAST typeOperand=kotlin.Double
GET_VAR 'y: kotlin.Any declared in <root>.testFD' type=kotlin.Any origin=null
arg1: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
@@ -131,7 +137,13 @@ FILE fqName:<root> fileName:/floatingPointLess.kt
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
then: ERROR_CALL 'Comparison of arguments with different types: kotlin/Double, kotlin/Float' type=kotlin.Boolean
then: CALL 'public final fun less (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=LT
arg0: CALL 'public final fun compareTo (other: kotlin.Float): kotlin.Int [operator] declared in kotlin.Double' type=kotlin.Int origin=null
$this: TYPE_OP type=kotlin.Double origin=IMPLICIT_CAST typeOperand=kotlin.Double
GET_VAR 'x: kotlin.Any declared in <root>.testDF' type=kotlin.Any origin=null
other: TYPE_OP type=kotlin.Float origin=IMPLICIT_CAST typeOperand=kotlin.Float
GET_VAR 'y: kotlin.Any declared in <root>.testDF' type=kotlin.Any origin=null
arg1: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
@@ -8,7 +8,12 @@ FILE fqName:<root> fileName:/nullableAnyAsIntToDouble.kt
BRANCH
if: TYPE_OP type=kotlin.Boolean origin=INSTANCEOF typeOperand=kotlin.Int
GET_VAR 'x: kotlin.Any? declared in <root>.test' type=kotlin.Any? origin=null
then: ERROR_CALL 'Comparison of arguments with different types: kotlin/Int, kotlin/Double' type=kotlin.Boolean
then: CALL 'public final fun less (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=LT
arg0: CALL 'public final fun compareTo (other: kotlin.Double): kotlin.Int [operator] declared in kotlin.Int' type=kotlin.Int origin=null
$this: TYPE_OP type=kotlin.Int origin=IMPLICIT_CAST typeOperand=kotlin.Int
GET_VAR 'x: kotlin.Any? declared in <root>.test' type=kotlin.Any? origin=null
other: GET_VAR 'y: kotlin.Double declared in <root>.test' type=kotlin.Double origin=null
arg1: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
+26 -4
View File
@@ -10,7 +10,11 @@ FILE fqName:<root> fileName:/kt23030.kt
VALUE_PARAMETER name:y index:1 type:kotlin.Char
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun testOverloadedCompareToCall (x: kotlin.Int, y: kotlin.Char): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with different types: kotlin/Int, kotlin/Char' type=kotlin.Boolean
CALL 'public final fun less (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=LT
arg0: CALL 'public final fun compareTo (c: kotlin.Char): kotlin.Int [operator] declared in <root>' type=kotlin.Int origin=null
$receiver: GET_VAR 'x: kotlin.Int declared in <root>.testOverloadedCompareToCall' type=kotlin.Int origin=null
c: GET_VAR 'y: kotlin.Char declared in <root>.testOverloadedCompareToCall' type=kotlin.Char origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:testOverloadedCompareToCallWithSmartCast visibility:public modality:FINAL <> (x:kotlin.Any, y:kotlin.Any) returnType:kotlin.Boolean
VALUE_PARAMETER name:x index:0 type:kotlin.Any
VALUE_PARAMETER name:y index:1 type:kotlin.Any
@@ -27,7 +31,13 @@ FILE fqName:<root> fileName:/kt23030.kt
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
then: ERROR_CALL 'Comparison of arguments with different types: kotlin/Int, kotlin/Char' type=kotlin.Boolean
then: CALL 'public final fun less (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=LT
arg0: CALL 'public final fun compareTo (c: kotlin.Char): kotlin.Int [operator] declared in <root>' type=kotlin.Int origin=null
$receiver: TYPE_OP type=kotlin.Int origin=IMPLICIT_CAST typeOperand=kotlin.Int
GET_VAR 'x: kotlin.Any declared in <root>.testOverloadedCompareToCallWithSmartCast' type=kotlin.Any origin=null
c: TYPE_OP type=kotlin.Char origin=IMPLICIT_CAST typeOperand=kotlin.Char
GET_VAR 'y: kotlin.Any declared in <root>.testOverloadedCompareToCallWithSmartCast' type=kotlin.Any origin=null
arg1: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
@@ -74,7 +84,12 @@ FILE fqName:<root> fileName:/kt23030.kt
VALUE_PARAMETER name:y index:1 type:kotlin.Char
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun testMemberExtensionCompareToCall (x: kotlin.Int, y: kotlin.Char): kotlin.Boolean declared in <root>.C'
ERROR_CALL 'Comparison of arguments with different types: kotlin/Int, kotlin/Char' type=kotlin.Boolean
CALL 'public final fun less (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=LT
arg0: CALL 'public final fun compareTo (c: kotlin.Char): kotlin.Int [operator] declared in <root>.C' type=kotlin.Int origin=null
$this: GET_VAR '<this>: <root>.C declared in <root>.C.testMemberExtensionCompareToCall' type=<root>.C origin=null
$receiver: GET_VAR 'x: kotlin.Int declared in <root>.C.testMemberExtensionCompareToCall' type=kotlin.Int origin=null
c: GET_VAR 'y: kotlin.Char declared in <root>.C.testMemberExtensionCompareToCall' type=kotlin.Char origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:testMemberExtensionCompareToCallWithSmartCast visibility:public modality:FINAL <> ($this:<root>.C, x:kotlin.Any, y:kotlin.Any) returnType:kotlin.Boolean
$this: VALUE_PARAMETER name:<this> type:<root>.C
VALUE_PARAMETER name:x index:0 type:kotlin.Any
@@ -92,7 +107,14 @@ FILE fqName:<root> fileName:/kt23030.kt
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
then: ERROR_CALL 'Comparison of arguments with different types: kotlin/Int, kotlin/Char' type=kotlin.Boolean
then: CALL 'public final fun less (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=LT
arg0: CALL 'public final fun compareTo (c: kotlin.Char): kotlin.Int [operator] declared in <root>.C' type=kotlin.Int origin=null
$this: GET_VAR '<this>: <root>.C declared in <root>.C.testMemberExtensionCompareToCallWithSmartCast' type=<root>.C origin=null
$receiver: TYPE_OP type=kotlin.Int origin=IMPLICIT_CAST typeOperand=kotlin.Int
GET_VAR 'x: kotlin.Any declared in <root>.C.testMemberExtensionCompareToCallWithSmartCast' type=kotlin.Any origin=null
c: TYPE_OP type=kotlin.Char origin=IMPLICIT_CAST typeOperand=kotlin.Char
GET_VAR 'y: kotlin.Any declared in <root>.C.testMemberExtensionCompareToCallWithSmartCast' type=kotlin.Any origin=null
arg1: CONST Int type=kotlin.Int value=0
BRANCH
if: CONST Boolean type=kotlin.Boolean value=true
then: CONST Boolean type=kotlin.Boolean value=false
@@ -4,49 +4,81 @@ FILE fqName:<root> fileName:/primitiveComparisons.kt
VALUE_PARAMETER name:b index:1 type:kotlin.Byte
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun btest1 (a: kotlin.Byte, b: kotlin.Byte): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: kotlin/Byte' type=kotlin.Boolean
CALL 'public final fun greater (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=GT
arg0: CALL 'public open fun compareTo (other: kotlin.Byte): kotlin.Int [operator] declared in kotlin.Byte' type=kotlin.Int origin=null
$this: GET_VAR 'a: kotlin.Byte declared in <root>.btest1' type=kotlin.Byte origin=null
other: GET_VAR 'b: kotlin.Byte declared in <root>.btest1' type=kotlin.Byte origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:btest2 visibility:public modality:FINAL <> (a:kotlin.Byte, b:kotlin.Byte) returnType:kotlin.Boolean
VALUE_PARAMETER name:a index:0 type:kotlin.Byte
VALUE_PARAMETER name:b index:1 type:kotlin.Byte
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun btest2 (a: kotlin.Byte, b: kotlin.Byte): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: kotlin/Byte' type=kotlin.Boolean
CALL 'public final fun less (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=LT
arg0: CALL 'public open fun compareTo (other: kotlin.Byte): kotlin.Int [operator] declared in kotlin.Byte' type=kotlin.Int origin=null
$this: GET_VAR 'a: kotlin.Byte declared in <root>.btest2' type=kotlin.Byte origin=null
other: GET_VAR 'b: kotlin.Byte declared in <root>.btest2' type=kotlin.Byte origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:btest3 visibility:public modality:FINAL <> (a:kotlin.Byte, b:kotlin.Byte) returnType:kotlin.Boolean
VALUE_PARAMETER name:a index:0 type:kotlin.Byte
VALUE_PARAMETER name:b index:1 type:kotlin.Byte
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun btest3 (a: kotlin.Byte, b: kotlin.Byte): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: kotlin/Byte' type=kotlin.Boolean
CALL 'public final fun greaterOrEqual (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=GTEQ
arg0: CALL 'public open fun compareTo (other: kotlin.Byte): kotlin.Int [operator] declared in kotlin.Byte' type=kotlin.Int origin=null
$this: GET_VAR 'a: kotlin.Byte declared in <root>.btest3' type=kotlin.Byte origin=null
other: GET_VAR 'b: kotlin.Byte declared in <root>.btest3' type=kotlin.Byte origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:btest4 visibility:public modality:FINAL <> (a:kotlin.Byte, b:kotlin.Byte) returnType:kotlin.Boolean
VALUE_PARAMETER name:a index:0 type:kotlin.Byte
VALUE_PARAMETER name:b index:1 type:kotlin.Byte
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun btest4 (a: kotlin.Byte, b: kotlin.Byte): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: kotlin/Byte' type=kotlin.Boolean
CALL 'public final fun lessOrEqual (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=LTEQ
arg0: CALL 'public open fun compareTo (other: kotlin.Byte): kotlin.Int [operator] declared in kotlin.Byte' type=kotlin.Int origin=null
$this: GET_VAR 'a: kotlin.Byte declared in <root>.btest4' type=kotlin.Byte origin=null
other: GET_VAR 'b: kotlin.Byte declared in <root>.btest4' type=kotlin.Byte origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:stest1 visibility:public modality:FINAL <> (a:kotlin.Short, b:kotlin.Short) returnType:kotlin.Boolean
VALUE_PARAMETER name:a index:0 type:kotlin.Short
VALUE_PARAMETER name:b index:1 type:kotlin.Short
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun stest1 (a: kotlin.Short, b: kotlin.Short): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: kotlin/Short' type=kotlin.Boolean
CALL 'public final fun greater (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=GT
arg0: CALL 'public open fun compareTo (other: kotlin.Short): kotlin.Int [operator] declared in kotlin.Short' type=kotlin.Int origin=null
$this: GET_VAR 'a: kotlin.Short declared in <root>.stest1' type=kotlin.Short origin=null
other: GET_VAR 'b: kotlin.Short declared in <root>.stest1' type=kotlin.Short origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:stest2 visibility:public modality:FINAL <> (a:kotlin.Short, b:kotlin.Short) returnType:kotlin.Boolean
VALUE_PARAMETER name:a index:0 type:kotlin.Short
VALUE_PARAMETER name:b index:1 type:kotlin.Short
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun stest2 (a: kotlin.Short, b: kotlin.Short): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: kotlin/Short' type=kotlin.Boolean
CALL 'public final fun less (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=LT
arg0: CALL 'public open fun compareTo (other: kotlin.Short): kotlin.Int [operator] declared in kotlin.Short' type=kotlin.Int origin=null
$this: GET_VAR 'a: kotlin.Short declared in <root>.stest2' type=kotlin.Short origin=null
other: GET_VAR 'b: kotlin.Short declared in <root>.stest2' type=kotlin.Short origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:stest3 visibility:public modality:FINAL <> (a:kotlin.Short, b:kotlin.Short) returnType:kotlin.Boolean
VALUE_PARAMETER name:a index:0 type:kotlin.Short
VALUE_PARAMETER name:b index:1 type:kotlin.Short
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun stest3 (a: kotlin.Short, b: kotlin.Short): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: kotlin/Short' type=kotlin.Boolean
CALL 'public final fun greaterOrEqual (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=GTEQ
arg0: CALL 'public open fun compareTo (other: kotlin.Short): kotlin.Int [operator] declared in kotlin.Short' type=kotlin.Int origin=null
$this: GET_VAR 'a: kotlin.Short declared in <root>.stest3' type=kotlin.Short origin=null
other: GET_VAR 'b: kotlin.Short declared in <root>.stest3' type=kotlin.Short origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:stest4 visibility:public modality:FINAL <> (a:kotlin.Short, b:kotlin.Short) returnType:kotlin.Boolean
VALUE_PARAMETER name:a index:0 type:kotlin.Short
VALUE_PARAMETER name:b index:1 type:kotlin.Short
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun stest4 (a: kotlin.Short, b: kotlin.Short): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: kotlin/Short' type=kotlin.Boolean
CALL 'public final fun lessOrEqual (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=LTEQ
arg0: CALL 'public open fun compareTo (other: kotlin.Short): kotlin.Int [operator] declared in kotlin.Short' type=kotlin.Int origin=null
$this: GET_VAR 'a: kotlin.Short declared in <root>.stest4' type=kotlin.Short origin=null
other: GET_VAR 'b: kotlin.Short declared in <root>.stest4' type=kotlin.Short origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:itest1 visibility:public modality:FINAL <> (a:kotlin.Int, b:kotlin.Int) returnType:kotlin.Boolean
VALUE_PARAMETER name:a index:0 type:kotlin.Int
VALUE_PARAMETER name:b index:1 type:kotlin.Int
@@ -4,22 +4,38 @@ FILE fqName:<root> fileName:/stringComparisons.kt
VALUE_PARAMETER name:b index:1 type:kotlin.String
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun test1 (a: kotlin.String, b: kotlin.String): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: kotlin/String' type=kotlin.Boolean
CALL 'public final fun greater (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=GT
arg0: CALL 'public open fun compareTo (other: kotlin.String): kotlin.Int [operator] declared in kotlin.String' type=kotlin.Int origin=null
$this: GET_VAR 'a: kotlin.String declared in <root>.test1' type=kotlin.String origin=null
other: GET_VAR 'b: kotlin.String declared in <root>.test1' type=kotlin.String origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:test2 visibility:public modality:FINAL <> (a:kotlin.String, b:kotlin.String) returnType:kotlin.Boolean
VALUE_PARAMETER name:a index:0 type:kotlin.String
VALUE_PARAMETER name:b index:1 type:kotlin.String
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun test2 (a: kotlin.String, b: kotlin.String): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: kotlin/String' type=kotlin.Boolean
CALL 'public final fun less (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=LT
arg0: CALL 'public open fun compareTo (other: kotlin.String): kotlin.Int [operator] declared in kotlin.String' type=kotlin.Int origin=null
$this: GET_VAR 'a: kotlin.String declared in <root>.test2' type=kotlin.String origin=null
other: GET_VAR 'b: kotlin.String declared in <root>.test2' type=kotlin.String origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:test3 visibility:public modality:FINAL <> (a:kotlin.String, b:kotlin.String) returnType:kotlin.Boolean
VALUE_PARAMETER name:a index:0 type:kotlin.String
VALUE_PARAMETER name:b index:1 type:kotlin.String
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun test3 (a: kotlin.String, b: kotlin.String): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: kotlin/String' type=kotlin.Boolean
CALL 'public final fun greaterOrEqual (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=GTEQ
arg0: CALL 'public open fun compareTo (other: kotlin.String): kotlin.Int [operator] declared in kotlin.String' type=kotlin.Int origin=null
$this: GET_VAR 'a: kotlin.String declared in <root>.test3' type=kotlin.String origin=null
other: GET_VAR 'b: kotlin.String declared in <root>.test3' type=kotlin.String origin=null
arg1: CONST Int type=kotlin.Int value=0
FUN name:test4 visibility:public modality:FINAL <> (a:kotlin.String, b:kotlin.String) returnType:kotlin.Boolean
VALUE_PARAMETER name:a index:0 type:kotlin.String
VALUE_PARAMETER name:b index:1 type:kotlin.String
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun test4 (a: kotlin.String, b: kotlin.String): kotlin.Boolean declared in <root>'
ERROR_CALL 'Comparison of arguments with unsupported type: kotlin/String' type=kotlin.Boolean
CALL 'public final fun lessOrEqual (arg0: kotlin.Int, arg1: kotlin.Int): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=LTEQ
arg0: CALL 'public open fun compareTo (other: kotlin.String): kotlin.Int [operator] declared in kotlin.String' type=kotlin.Int origin=null
$this: GET_VAR 'a: kotlin.String declared in <root>.test4' type=kotlin.String origin=null
other: GET_VAR 'b: kotlin.String declared in <root>.test4' type=kotlin.String origin=null
arg1: CONST Int type=kotlin.Int value=0