JVM_IR KT-48432 fix overflow in const-bound range optimization
This commit is contained in:
committed by
TeamCityServer
parent
ce44403d1b
commit
c2b575505a
+6
@@ -0,0 +1,6 @@
|
||||
fun box(): String {
|
||||
val x1 = 1.toChar()
|
||||
if (x1 !in Char.MIN_VALUE..Char.MAX_VALUE)
|
||||
return "Failed"
|
||||
return "OK"
|
||||
}
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
fun box(): String {
|
||||
val x1 = 1
|
||||
if (x1 !in Byte.MIN_VALUE..Byte.MAX_VALUE)
|
||||
return "Failed"
|
||||
return "OK"
|
||||
}
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
fun box(): String {
|
||||
val x1 = 1
|
||||
if (x1 !in Int.MIN_VALUE..Int.MAX_VALUE)
|
||||
return "Failed"
|
||||
return "OK"
|
||||
}
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
fun box(): String {
|
||||
val x1 = 1
|
||||
if (x1 !in Short.MIN_VALUE..Short.MAX_VALUE)
|
||||
return "Failed"
|
||||
return "OK"
|
||||
}
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
fun box(): String {
|
||||
val x1 = 1L
|
||||
if (x1 !in Long.MIN_VALUE..Long.MAX_VALUE)
|
||||
return "Failed"
|
||||
return "OK"
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
// WITH_RUNTIME
|
||||
|
||||
fun box(): String {
|
||||
val x1 = 1U
|
||||
if (x1 !in UByte.MIN_VALUE..UByte.MAX_VALUE)
|
||||
return "Failed"
|
||||
return "OK"
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
// WITH_RUNTIME
|
||||
|
||||
fun box(): String {
|
||||
val x1 = 1U
|
||||
if (x1 !in UInt.MIN_VALUE..UInt.MAX_VALUE)
|
||||
return "Failed"
|
||||
return "OK"
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
// WITH_RUNTIME
|
||||
|
||||
fun box(): String {
|
||||
val x1 = 1U
|
||||
if (x1 !in UShort.MIN_VALUE..UShort.MAX_VALUE)
|
||||
return "Failed"
|
||||
return "OK"
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
// WITH_RUNTIME
|
||||
|
||||
fun box(): String {
|
||||
val x1 = 1UL
|
||||
if (x1 !in ULong.MIN_VALUE..ULong.MAX_VALUE)
|
||||
return "Failed"
|
||||
return "OK"
|
||||
}
|
||||
Reference in New Issue
Block a user