FIR: Support FirComparisonOperator in Fir2Ir
^KT-31163 Fixed
This commit is contained in:
@@ -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
@@ -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)"
|
||||
|
||||
Reference in New Issue
Block a user