diff --git a/compiler/testData/codegen/box/ranges/contains/generated/arrayIndices.kt b/compiler/testData/codegen/box/ranges/contains/generated/arrayIndices.kt index 9bfdbcf833f..89988d102c3 100644 --- a/compiler/testData/codegen/box/ranges/contains/generated/arrayIndices.kt +++ b/compiler/testData/codegen/box/ranges/contains/generated/arrayIndices.kt @@ -16,38 +16,26 @@ val element0 = (-1).toByte() val element1 = (-1).toShort() val element2 = (-1) val element3 = (-1).toLong() -val element4 = (-1).toFloat() -val element5 = (-1).toDouble() -val element6 = 0.toByte() -val element7 = 0.toShort() -val element8 = 0 -val element9 = 0.toLong() -val element10 = 0.toFloat() -val element11 = 0.toDouble() -val element12 = 1.toByte() -val element13 = 1.toShort() -val element14 = 1 -val element15 = 1.toLong() -val element16 = 1.toFloat() -val element17 = 1.toDouble() -val element18 = 2.toByte() -val element19 = 2.toShort() -val element20 = 2 -val element21 = 2.toLong() -val element22 = 2.toFloat() -val element23 = 2.toDouble() -val element24 = 3.toByte() -val element25 = 3.toShort() -val element26 = 3 -val element27 = 3.toLong() -val element28 = 3.toFloat() -val element29 = 3.toDouble() -val element30 = 4.toByte() -val element31 = 4.toShort() -val element32 = 4 -val element33 = 4.toLong() -val element34 = 4.toFloat() -val element35 = 4.toDouble() +val element4 = 0.toByte() +val element5 = 0.toShort() +val element6 = 0 +val element7 = 0.toLong() +val element8 = 1.toByte() +val element9 = 1.toShort() +val element10 = 1 +val element11 = 1.toLong() +val element12 = 2.toByte() +val element13 = 2.toShort() +val element14 = 2 +val element15 = 2.toLong() +val element16 = 3.toByte() +val element17 = 3.toShort() +val element18 = 3 +val element19 = 3.toLong() +val element20 = 4.toByte() +val element21 = 4.toShort() +val element22 = 4 +val element23 = 4.toLong() fun box(): String { testR0xE0() @@ -74,18 +62,6 @@ fun box(): String { testR0xE21() testR0xE22() testR0xE23() - testR0xE24() - testR0xE25() - testR0xE26() - testR0xE27() - testR0xE28() - testR0xE29() - testR0xE30() - testR0xE31() - testR0xE32() - testR0xE33() - testR0xE34() - testR0xE35() testR1xE0() testR1xE1() testR1xE2() @@ -110,18 +86,6 @@ fun box(): String { testR1xE21() testR1xE22() testR1xE23() - testR1xE24() - testR1xE25() - testR1xE26() - testR1xE27() - testR1xE28() - testR1xE29() - testR1xE30() - testR1xE31() - testR1xE32() - testR1xE33() - testR1xE34() - testR1xE35() testR2xE0() testR2xE1() testR2xE2() @@ -146,18 +110,6 @@ fun box(): String { testR2xE21() testR2xE22() testR2xE23() - testR2xE24() - testR2xE25() - testR2xE26() - testR2xE27() - testR2xE28() - testR2xE29() - testR2xE30() - testR2xE31() - testR2xE32() - testR2xE33() - testR2xE34() - testR2xE35() testR3xE0() testR3xE1() testR3xE2() @@ -182,18 +134,6 @@ fun box(): String { testR3xE21() testR3xE22() testR3xE23() - testR3xE24() - testR3xE25() - testR3xE26() - testR3xE27() - testR3xE28() - testR3xE29() - testR3xE30() - testR3xE31() - testR3xE32() - testR3xE33() - testR3xE34() - testR3xE35() return "OK" } @@ -251,10 +191,10 @@ fun testR0xE3() { fun testR0xE4() { // with possible local optimizations - if ((-1).toFloat() in intArray.indices != range0.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in intArray.indices != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in intArray.indices) != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in intArray.indices) != range0.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in intArray.indices != range0.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in intArray.indices != !range0.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in intArray.indices) != !range0.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in intArray.indices) != range0.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in intArray.indices != range0.contains(element4)) throw AssertionError() if (element4 !in intArray.indices != !range0.contains(element4)) throw AssertionError() @@ -264,10 +204,10 @@ fun testR0xE4() { fun testR0xE5() { // with possible local optimizations - if ((-1).toDouble() in intArray.indices != range0.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in intArray.indices != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in intArray.indices) != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in intArray.indices) != range0.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in intArray.indices != range0.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in intArray.indices != !range0.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in intArray.indices) != !range0.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in intArray.indices) != range0.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in intArray.indices != range0.contains(element5)) throw AssertionError() if (element5 !in intArray.indices != !range0.contains(element5)) throw AssertionError() @@ -277,10 +217,10 @@ fun testR0xE5() { fun testR0xE6() { // with possible local optimizations - if (0.toByte() in intArray.indices != range0.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in intArray.indices != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in intArray.indices) != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in intArray.indices) != range0.contains(0.toByte())) throw AssertionError() + if (0 in intArray.indices != range0.contains(0)) throw AssertionError() + if (0 !in intArray.indices != !range0.contains(0)) throw AssertionError() + if (!(0 in intArray.indices) != !range0.contains(0)) throw AssertionError() + if (!(0 !in intArray.indices) != range0.contains(0)) throw AssertionError() // no local optimizations if (element6 in intArray.indices != range0.contains(element6)) throw AssertionError() if (element6 !in intArray.indices != !range0.contains(element6)) throw AssertionError() @@ -290,10 +230,10 @@ fun testR0xE6() { fun testR0xE7() { // with possible local optimizations - if (0.toShort() in intArray.indices != range0.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in intArray.indices != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in intArray.indices) != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in intArray.indices) != range0.contains(0.toShort())) throw AssertionError() + if (0.toLong() in intArray.indices != range0.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in intArray.indices != !range0.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in intArray.indices) != !range0.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in intArray.indices) != range0.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in intArray.indices != range0.contains(element7)) throw AssertionError() if (element7 !in intArray.indices != !range0.contains(element7)) throw AssertionError() @@ -303,10 +243,10 @@ fun testR0xE7() { fun testR0xE8() { // with possible local optimizations - if (0 in intArray.indices != range0.contains(0)) throw AssertionError() - if (0 !in intArray.indices != !range0.contains(0)) throw AssertionError() - if (!(0 in intArray.indices) != !range0.contains(0)) throw AssertionError() - if (!(0 !in intArray.indices) != range0.contains(0)) throw AssertionError() + if (1.toByte() in intArray.indices != range0.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in intArray.indices != !range0.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in intArray.indices) != !range0.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in intArray.indices) != range0.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in intArray.indices != range0.contains(element8)) throw AssertionError() if (element8 !in intArray.indices != !range0.contains(element8)) throw AssertionError() @@ -316,10 +256,10 @@ fun testR0xE8() { fun testR0xE9() { // with possible local optimizations - if (0.toLong() in intArray.indices != range0.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in intArray.indices != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in intArray.indices) != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in intArray.indices) != range0.contains(0.toLong())) throw AssertionError() + if (1.toShort() in intArray.indices != range0.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in intArray.indices != !range0.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in intArray.indices) != !range0.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in intArray.indices) != range0.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in intArray.indices != range0.contains(element9)) throw AssertionError() if (element9 !in intArray.indices != !range0.contains(element9)) throw AssertionError() @@ -329,10 +269,10 @@ fun testR0xE9() { fun testR0xE10() { // with possible local optimizations - if (0.toFloat() in intArray.indices != range0.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in intArray.indices != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in intArray.indices) != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in intArray.indices) != range0.contains(0.toFloat())) throw AssertionError() + if (1 in intArray.indices != range0.contains(1)) throw AssertionError() + if (1 !in intArray.indices != !range0.contains(1)) throw AssertionError() + if (!(1 in intArray.indices) != !range0.contains(1)) throw AssertionError() + if (!(1 !in intArray.indices) != range0.contains(1)) throw AssertionError() // no local optimizations if (element10 in intArray.indices != range0.contains(element10)) throw AssertionError() if (element10 !in intArray.indices != !range0.contains(element10)) throw AssertionError() @@ -342,10 +282,10 @@ fun testR0xE10() { fun testR0xE11() { // with possible local optimizations - if (0.toDouble() in intArray.indices != range0.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in intArray.indices != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in intArray.indices) != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in intArray.indices) != range0.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in intArray.indices != range0.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in intArray.indices != !range0.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in intArray.indices) != !range0.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in intArray.indices) != range0.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in intArray.indices != range0.contains(element11)) throw AssertionError() if (element11 !in intArray.indices != !range0.contains(element11)) throw AssertionError() @@ -355,10 +295,10 @@ fun testR0xE11() { fun testR0xE12() { // with possible local optimizations - if (1.toByte() in intArray.indices != range0.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in intArray.indices != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in intArray.indices) != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in intArray.indices) != range0.contains(1.toByte())) throw AssertionError() + if (2.toByte() in intArray.indices != range0.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in intArray.indices != !range0.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in intArray.indices) != !range0.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in intArray.indices) != range0.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in intArray.indices != range0.contains(element12)) throw AssertionError() if (element12 !in intArray.indices != !range0.contains(element12)) throw AssertionError() @@ -368,10 +308,10 @@ fun testR0xE12() { fun testR0xE13() { // with possible local optimizations - if (1.toShort() in intArray.indices != range0.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in intArray.indices != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in intArray.indices) != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in intArray.indices) != range0.contains(1.toShort())) throw AssertionError() + if (2.toShort() in intArray.indices != range0.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in intArray.indices != !range0.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in intArray.indices) != !range0.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in intArray.indices) != range0.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in intArray.indices != range0.contains(element13)) throw AssertionError() if (element13 !in intArray.indices != !range0.contains(element13)) throw AssertionError() @@ -381,10 +321,10 @@ fun testR0xE13() { fun testR0xE14() { // with possible local optimizations - if (1 in intArray.indices != range0.contains(1)) throw AssertionError() - if (1 !in intArray.indices != !range0.contains(1)) throw AssertionError() - if (!(1 in intArray.indices) != !range0.contains(1)) throw AssertionError() - if (!(1 !in intArray.indices) != range0.contains(1)) throw AssertionError() + if (2 in intArray.indices != range0.contains(2)) throw AssertionError() + if (2 !in intArray.indices != !range0.contains(2)) throw AssertionError() + if (!(2 in intArray.indices) != !range0.contains(2)) throw AssertionError() + if (!(2 !in intArray.indices) != range0.contains(2)) throw AssertionError() // no local optimizations if (element14 in intArray.indices != range0.contains(element14)) throw AssertionError() if (element14 !in intArray.indices != !range0.contains(element14)) throw AssertionError() @@ -394,10 +334,10 @@ fun testR0xE14() { fun testR0xE15() { // with possible local optimizations - if (1.toLong() in intArray.indices != range0.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in intArray.indices != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in intArray.indices) != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in intArray.indices) != range0.contains(1.toLong())) throw AssertionError() + if (2.toLong() in intArray.indices != range0.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in intArray.indices != !range0.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in intArray.indices) != !range0.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in intArray.indices) != range0.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in intArray.indices != range0.contains(element15)) throw AssertionError() if (element15 !in intArray.indices != !range0.contains(element15)) throw AssertionError() @@ -407,10 +347,10 @@ fun testR0xE15() { fun testR0xE16() { // with possible local optimizations - if (1.toFloat() in intArray.indices != range0.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in intArray.indices != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in intArray.indices) != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in intArray.indices) != range0.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in intArray.indices != range0.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in intArray.indices != !range0.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in intArray.indices) != !range0.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in intArray.indices) != range0.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in intArray.indices != range0.contains(element16)) throw AssertionError() if (element16 !in intArray.indices != !range0.contains(element16)) throw AssertionError() @@ -420,10 +360,10 @@ fun testR0xE16() { fun testR0xE17() { // with possible local optimizations - if (1.toDouble() in intArray.indices != range0.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in intArray.indices != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in intArray.indices) != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in intArray.indices) != range0.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in intArray.indices != range0.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in intArray.indices != !range0.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in intArray.indices) != !range0.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in intArray.indices) != range0.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in intArray.indices != range0.contains(element17)) throw AssertionError() if (element17 !in intArray.indices != !range0.contains(element17)) throw AssertionError() @@ -433,10 +373,10 @@ fun testR0xE17() { fun testR0xE18() { // with possible local optimizations - if (2.toByte() in intArray.indices != range0.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in intArray.indices != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in intArray.indices) != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in intArray.indices) != range0.contains(2.toByte())) throw AssertionError() + if (3 in intArray.indices != range0.contains(3)) throw AssertionError() + if (3 !in intArray.indices != !range0.contains(3)) throw AssertionError() + if (!(3 in intArray.indices) != !range0.contains(3)) throw AssertionError() + if (!(3 !in intArray.indices) != range0.contains(3)) throw AssertionError() // no local optimizations if (element18 in intArray.indices != range0.contains(element18)) throw AssertionError() if (element18 !in intArray.indices != !range0.contains(element18)) throw AssertionError() @@ -446,10 +386,10 @@ fun testR0xE18() { fun testR0xE19() { // with possible local optimizations - if (2.toShort() in intArray.indices != range0.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in intArray.indices != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in intArray.indices) != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in intArray.indices) != range0.contains(2.toShort())) throw AssertionError() + if (3.toLong() in intArray.indices != range0.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in intArray.indices != !range0.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in intArray.indices) != !range0.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in intArray.indices) != range0.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in intArray.indices != range0.contains(element19)) throw AssertionError() if (element19 !in intArray.indices != !range0.contains(element19)) throw AssertionError() @@ -459,10 +399,10 @@ fun testR0xE19() { fun testR0xE20() { // with possible local optimizations - if (2 in intArray.indices != range0.contains(2)) throw AssertionError() - if (2 !in intArray.indices != !range0.contains(2)) throw AssertionError() - if (!(2 in intArray.indices) != !range0.contains(2)) throw AssertionError() - if (!(2 !in intArray.indices) != range0.contains(2)) throw AssertionError() + if (4.toByte() in intArray.indices != range0.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in intArray.indices != !range0.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in intArray.indices) != !range0.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in intArray.indices) != range0.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in intArray.indices != range0.contains(element20)) throw AssertionError() if (element20 !in intArray.indices != !range0.contains(element20)) throw AssertionError() @@ -472,10 +412,10 @@ fun testR0xE20() { fun testR0xE21() { // with possible local optimizations - if (2.toLong() in intArray.indices != range0.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in intArray.indices != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in intArray.indices) != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in intArray.indices) != range0.contains(2.toLong())) throw AssertionError() + if (4.toShort() in intArray.indices != range0.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in intArray.indices != !range0.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in intArray.indices) != !range0.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in intArray.indices) != range0.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in intArray.indices != range0.contains(element21)) throw AssertionError() if (element21 !in intArray.indices != !range0.contains(element21)) throw AssertionError() @@ -485,10 +425,10 @@ fun testR0xE21() { fun testR0xE22() { // with possible local optimizations - if (2.toFloat() in intArray.indices != range0.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in intArray.indices != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in intArray.indices) != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in intArray.indices) != range0.contains(2.toFloat())) throw AssertionError() + if (4 in intArray.indices != range0.contains(4)) throw AssertionError() + if (4 !in intArray.indices != !range0.contains(4)) throw AssertionError() + if (!(4 in intArray.indices) != !range0.contains(4)) throw AssertionError() + if (!(4 !in intArray.indices) != range0.contains(4)) throw AssertionError() // no local optimizations if (element22 in intArray.indices != range0.contains(element22)) throw AssertionError() if (element22 !in intArray.indices != !range0.contains(element22)) throw AssertionError() @@ -497,172 +437,16 @@ fun testR0xE22() { } fun testR0xE23() { - // with possible local optimizations - if (2.toDouble() in intArray.indices != range0.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in intArray.indices != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in intArray.indices) != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in intArray.indices) != range0.contains(2.toDouble())) throw AssertionError() - // no local optimizations - if (element23 in intArray.indices != range0.contains(element23)) throw AssertionError() - if (element23 !in intArray.indices != !range0.contains(element23)) throw AssertionError() - if (!(element23 in intArray.indices) != !range0.contains(element23)) throw AssertionError() - if (!(element23 !in intArray.indices) != range0.contains(element23)) throw AssertionError() -} - -fun testR0xE24() { - // with possible local optimizations - if (3.toByte() in intArray.indices != range0.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in intArray.indices != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in intArray.indices) != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in intArray.indices) != range0.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in intArray.indices != range0.contains(element24)) throw AssertionError() - if (element24 !in intArray.indices != !range0.contains(element24)) throw AssertionError() - if (!(element24 in intArray.indices) != !range0.contains(element24)) throw AssertionError() - if (!(element24 !in intArray.indices) != range0.contains(element24)) throw AssertionError() -} - -fun testR0xE25() { - // with possible local optimizations - if (3.toShort() in intArray.indices != range0.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in intArray.indices != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in intArray.indices) != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in intArray.indices) != range0.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in intArray.indices != range0.contains(element25)) throw AssertionError() - if (element25 !in intArray.indices != !range0.contains(element25)) throw AssertionError() - if (!(element25 in intArray.indices) != !range0.contains(element25)) throw AssertionError() - if (!(element25 !in intArray.indices) != range0.contains(element25)) throw AssertionError() -} - -fun testR0xE26() { - // with possible local optimizations - if (3 in intArray.indices != range0.contains(3)) throw AssertionError() - if (3 !in intArray.indices != !range0.contains(3)) throw AssertionError() - if (!(3 in intArray.indices) != !range0.contains(3)) throw AssertionError() - if (!(3 !in intArray.indices) != range0.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in intArray.indices != range0.contains(element26)) throw AssertionError() - if (element26 !in intArray.indices != !range0.contains(element26)) throw AssertionError() - if (!(element26 in intArray.indices) != !range0.contains(element26)) throw AssertionError() - if (!(element26 !in intArray.indices) != range0.contains(element26)) throw AssertionError() -} - -fun testR0xE27() { - // with possible local optimizations - if (3.toLong() in intArray.indices != range0.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in intArray.indices != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in intArray.indices) != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in intArray.indices) != range0.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in intArray.indices != range0.contains(element27)) throw AssertionError() - if (element27 !in intArray.indices != !range0.contains(element27)) throw AssertionError() - if (!(element27 in intArray.indices) != !range0.contains(element27)) throw AssertionError() - if (!(element27 !in intArray.indices) != range0.contains(element27)) throw AssertionError() -} - -fun testR0xE28() { - // with possible local optimizations - if (3.toFloat() in intArray.indices != range0.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in intArray.indices != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in intArray.indices) != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in intArray.indices) != range0.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in intArray.indices != range0.contains(element28)) throw AssertionError() - if (element28 !in intArray.indices != !range0.contains(element28)) throw AssertionError() - if (!(element28 in intArray.indices) != !range0.contains(element28)) throw AssertionError() - if (!(element28 !in intArray.indices) != range0.contains(element28)) throw AssertionError() -} - -fun testR0xE29() { - // with possible local optimizations - if (3.toDouble() in intArray.indices != range0.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in intArray.indices != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in intArray.indices) != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in intArray.indices) != range0.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in intArray.indices != range0.contains(element29)) throw AssertionError() - if (element29 !in intArray.indices != !range0.contains(element29)) throw AssertionError() - if (!(element29 in intArray.indices) != !range0.contains(element29)) throw AssertionError() - if (!(element29 !in intArray.indices) != range0.contains(element29)) throw AssertionError() -} - -fun testR0xE30() { - // with possible local optimizations - if (4.toByte() in intArray.indices != range0.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in intArray.indices != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in intArray.indices) != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in intArray.indices) != range0.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in intArray.indices != range0.contains(element30)) throw AssertionError() - if (element30 !in intArray.indices != !range0.contains(element30)) throw AssertionError() - if (!(element30 in intArray.indices) != !range0.contains(element30)) throw AssertionError() - if (!(element30 !in intArray.indices) != range0.contains(element30)) throw AssertionError() -} - -fun testR0xE31() { - // with possible local optimizations - if (4.toShort() in intArray.indices != range0.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in intArray.indices != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in intArray.indices) != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in intArray.indices) != range0.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in intArray.indices != range0.contains(element31)) throw AssertionError() - if (element31 !in intArray.indices != !range0.contains(element31)) throw AssertionError() - if (!(element31 in intArray.indices) != !range0.contains(element31)) throw AssertionError() - if (!(element31 !in intArray.indices) != range0.contains(element31)) throw AssertionError() -} - -fun testR0xE32() { - // with possible local optimizations - if (4 in intArray.indices != range0.contains(4)) throw AssertionError() - if (4 !in intArray.indices != !range0.contains(4)) throw AssertionError() - if (!(4 in intArray.indices) != !range0.contains(4)) throw AssertionError() - if (!(4 !in intArray.indices) != range0.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in intArray.indices != range0.contains(element32)) throw AssertionError() - if (element32 !in intArray.indices != !range0.contains(element32)) throw AssertionError() - if (!(element32 in intArray.indices) != !range0.contains(element32)) throw AssertionError() - if (!(element32 !in intArray.indices) != range0.contains(element32)) throw AssertionError() -} - -fun testR0xE33() { // with possible local optimizations if (4.toLong() in intArray.indices != range0.contains(4.toLong())) throw AssertionError() if (4.toLong() !in intArray.indices != !range0.contains(4.toLong())) throw AssertionError() if (!(4.toLong() in intArray.indices) != !range0.contains(4.toLong())) throw AssertionError() if (!(4.toLong() !in intArray.indices) != range0.contains(4.toLong())) throw AssertionError() // no local optimizations - if (element33 in intArray.indices != range0.contains(element33)) throw AssertionError() - if (element33 !in intArray.indices != !range0.contains(element33)) throw AssertionError() - if (!(element33 in intArray.indices) != !range0.contains(element33)) throw AssertionError() - if (!(element33 !in intArray.indices) != range0.contains(element33)) throw AssertionError() -} - -fun testR0xE34() { - // with possible local optimizations - if (4.toFloat() in intArray.indices != range0.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in intArray.indices != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in intArray.indices) != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in intArray.indices) != range0.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in intArray.indices != range0.contains(element34)) throw AssertionError() - if (element34 !in intArray.indices != !range0.contains(element34)) throw AssertionError() - if (!(element34 in intArray.indices) != !range0.contains(element34)) throw AssertionError() - if (!(element34 !in intArray.indices) != range0.contains(element34)) throw AssertionError() -} - -fun testR0xE35() { - // with possible local optimizations - if (4.toDouble() in intArray.indices != range0.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in intArray.indices != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in intArray.indices) != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in intArray.indices) != range0.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in intArray.indices != range0.contains(element35)) throw AssertionError() - if (element35 !in intArray.indices != !range0.contains(element35)) throw AssertionError() - if (!(element35 in intArray.indices) != !range0.contains(element35)) throw AssertionError() - if (!(element35 !in intArray.indices) != range0.contains(element35)) throw AssertionError() + if (element23 in intArray.indices != range0.contains(element23)) throw AssertionError() + if (element23 !in intArray.indices != !range0.contains(element23)) throw AssertionError() + if (!(element23 in intArray.indices) != !range0.contains(element23)) throw AssertionError() + if (!(element23 !in intArray.indices) != range0.contains(element23)) throw AssertionError() } fun testR1xE0() { @@ -719,10 +503,10 @@ fun testR1xE3() { fun testR1xE4() { // with possible local optimizations - if ((-1).toFloat() in objectArray.indices != range1.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in objectArray.indices != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in objectArray.indices) != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in objectArray.indices) != range1.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in objectArray.indices != range1.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in objectArray.indices != !range1.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in objectArray.indices) != !range1.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in objectArray.indices) != range1.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in objectArray.indices != range1.contains(element4)) throw AssertionError() if (element4 !in objectArray.indices != !range1.contains(element4)) throw AssertionError() @@ -732,10 +516,10 @@ fun testR1xE4() { fun testR1xE5() { // with possible local optimizations - if ((-1).toDouble() in objectArray.indices != range1.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in objectArray.indices != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in objectArray.indices) != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in objectArray.indices) != range1.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in objectArray.indices != range1.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in objectArray.indices != !range1.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in objectArray.indices) != !range1.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in objectArray.indices) != range1.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in objectArray.indices != range1.contains(element5)) throw AssertionError() if (element5 !in objectArray.indices != !range1.contains(element5)) throw AssertionError() @@ -745,10 +529,10 @@ fun testR1xE5() { fun testR1xE6() { // with possible local optimizations - if (0.toByte() in objectArray.indices != range1.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in objectArray.indices != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in objectArray.indices) != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in objectArray.indices) != range1.contains(0.toByte())) throw AssertionError() + if (0 in objectArray.indices != range1.contains(0)) throw AssertionError() + if (0 !in objectArray.indices != !range1.contains(0)) throw AssertionError() + if (!(0 in objectArray.indices) != !range1.contains(0)) throw AssertionError() + if (!(0 !in objectArray.indices) != range1.contains(0)) throw AssertionError() // no local optimizations if (element6 in objectArray.indices != range1.contains(element6)) throw AssertionError() if (element6 !in objectArray.indices != !range1.contains(element6)) throw AssertionError() @@ -758,10 +542,10 @@ fun testR1xE6() { fun testR1xE7() { // with possible local optimizations - if (0.toShort() in objectArray.indices != range1.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in objectArray.indices != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in objectArray.indices) != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in objectArray.indices) != range1.contains(0.toShort())) throw AssertionError() + if (0.toLong() in objectArray.indices != range1.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in objectArray.indices != !range1.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in objectArray.indices) != !range1.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in objectArray.indices) != range1.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in objectArray.indices != range1.contains(element7)) throw AssertionError() if (element7 !in objectArray.indices != !range1.contains(element7)) throw AssertionError() @@ -771,10 +555,10 @@ fun testR1xE7() { fun testR1xE8() { // with possible local optimizations - if (0 in objectArray.indices != range1.contains(0)) throw AssertionError() - if (0 !in objectArray.indices != !range1.contains(0)) throw AssertionError() - if (!(0 in objectArray.indices) != !range1.contains(0)) throw AssertionError() - if (!(0 !in objectArray.indices) != range1.contains(0)) throw AssertionError() + if (1.toByte() in objectArray.indices != range1.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in objectArray.indices != !range1.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in objectArray.indices) != !range1.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in objectArray.indices) != range1.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in objectArray.indices != range1.contains(element8)) throw AssertionError() if (element8 !in objectArray.indices != !range1.contains(element8)) throw AssertionError() @@ -784,10 +568,10 @@ fun testR1xE8() { fun testR1xE9() { // with possible local optimizations - if (0.toLong() in objectArray.indices != range1.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in objectArray.indices != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in objectArray.indices) != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in objectArray.indices) != range1.contains(0.toLong())) throw AssertionError() + if (1.toShort() in objectArray.indices != range1.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in objectArray.indices != !range1.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in objectArray.indices) != !range1.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in objectArray.indices) != range1.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in objectArray.indices != range1.contains(element9)) throw AssertionError() if (element9 !in objectArray.indices != !range1.contains(element9)) throw AssertionError() @@ -797,10 +581,10 @@ fun testR1xE9() { fun testR1xE10() { // with possible local optimizations - if (0.toFloat() in objectArray.indices != range1.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in objectArray.indices != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in objectArray.indices) != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in objectArray.indices) != range1.contains(0.toFloat())) throw AssertionError() + if (1 in objectArray.indices != range1.contains(1)) throw AssertionError() + if (1 !in objectArray.indices != !range1.contains(1)) throw AssertionError() + if (!(1 in objectArray.indices) != !range1.contains(1)) throw AssertionError() + if (!(1 !in objectArray.indices) != range1.contains(1)) throw AssertionError() // no local optimizations if (element10 in objectArray.indices != range1.contains(element10)) throw AssertionError() if (element10 !in objectArray.indices != !range1.contains(element10)) throw AssertionError() @@ -810,10 +594,10 @@ fun testR1xE10() { fun testR1xE11() { // with possible local optimizations - if (0.toDouble() in objectArray.indices != range1.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in objectArray.indices != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in objectArray.indices) != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in objectArray.indices) != range1.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in objectArray.indices != range1.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in objectArray.indices != !range1.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in objectArray.indices) != !range1.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in objectArray.indices) != range1.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in objectArray.indices != range1.contains(element11)) throw AssertionError() if (element11 !in objectArray.indices != !range1.contains(element11)) throw AssertionError() @@ -823,10 +607,10 @@ fun testR1xE11() { fun testR1xE12() { // with possible local optimizations - if (1.toByte() in objectArray.indices != range1.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in objectArray.indices != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in objectArray.indices) != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in objectArray.indices) != range1.contains(1.toByte())) throw AssertionError() + if (2.toByte() in objectArray.indices != range1.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in objectArray.indices != !range1.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in objectArray.indices) != !range1.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in objectArray.indices) != range1.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in objectArray.indices != range1.contains(element12)) throw AssertionError() if (element12 !in objectArray.indices != !range1.contains(element12)) throw AssertionError() @@ -836,10 +620,10 @@ fun testR1xE12() { fun testR1xE13() { // with possible local optimizations - if (1.toShort() in objectArray.indices != range1.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in objectArray.indices != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in objectArray.indices) != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in objectArray.indices) != range1.contains(1.toShort())) throw AssertionError() + if (2.toShort() in objectArray.indices != range1.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in objectArray.indices != !range1.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in objectArray.indices) != !range1.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in objectArray.indices) != range1.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in objectArray.indices != range1.contains(element13)) throw AssertionError() if (element13 !in objectArray.indices != !range1.contains(element13)) throw AssertionError() @@ -849,10 +633,10 @@ fun testR1xE13() { fun testR1xE14() { // with possible local optimizations - if (1 in objectArray.indices != range1.contains(1)) throw AssertionError() - if (1 !in objectArray.indices != !range1.contains(1)) throw AssertionError() - if (!(1 in objectArray.indices) != !range1.contains(1)) throw AssertionError() - if (!(1 !in objectArray.indices) != range1.contains(1)) throw AssertionError() + if (2 in objectArray.indices != range1.contains(2)) throw AssertionError() + if (2 !in objectArray.indices != !range1.contains(2)) throw AssertionError() + if (!(2 in objectArray.indices) != !range1.contains(2)) throw AssertionError() + if (!(2 !in objectArray.indices) != range1.contains(2)) throw AssertionError() // no local optimizations if (element14 in objectArray.indices != range1.contains(element14)) throw AssertionError() if (element14 !in objectArray.indices != !range1.contains(element14)) throw AssertionError() @@ -862,10 +646,10 @@ fun testR1xE14() { fun testR1xE15() { // with possible local optimizations - if (1.toLong() in objectArray.indices != range1.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in objectArray.indices != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in objectArray.indices) != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in objectArray.indices) != range1.contains(1.toLong())) throw AssertionError() + if (2.toLong() in objectArray.indices != range1.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in objectArray.indices != !range1.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in objectArray.indices) != !range1.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in objectArray.indices) != range1.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in objectArray.indices != range1.contains(element15)) throw AssertionError() if (element15 !in objectArray.indices != !range1.contains(element15)) throw AssertionError() @@ -875,10 +659,10 @@ fun testR1xE15() { fun testR1xE16() { // with possible local optimizations - if (1.toFloat() in objectArray.indices != range1.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in objectArray.indices != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in objectArray.indices) != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in objectArray.indices) != range1.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in objectArray.indices != range1.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in objectArray.indices != !range1.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in objectArray.indices) != !range1.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in objectArray.indices) != range1.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in objectArray.indices != range1.contains(element16)) throw AssertionError() if (element16 !in objectArray.indices != !range1.contains(element16)) throw AssertionError() @@ -888,10 +672,10 @@ fun testR1xE16() { fun testR1xE17() { // with possible local optimizations - if (1.toDouble() in objectArray.indices != range1.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in objectArray.indices != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in objectArray.indices) != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in objectArray.indices) != range1.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in objectArray.indices != range1.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in objectArray.indices != !range1.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in objectArray.indices) != !range1.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in objectArray.indices) != range1.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in objectArray.indices != range1.contains(element17)) throw AssertionError() if (element17 !in objectArray.indices != !range1.contains(element17)) throw AssertionError() @@ -901,10 +685,10 @@ fun testR1xE17() { fun testR1xE18() { // with possible local optimizations - if (2.toByte() in objectArray.indices != range1.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in objectArray.indices != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in objectArray.indices) != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in objectArray.indices) != range1.contains(2.toByte())) throw AssertionError() + if (3 in objectArray.indices != range1.contains(3)) throw AssertionError() + if (3 !in objectArray.indices != !range1.contains(3)) throw AssertionError() + if (!(3 in objectArray.indices) != !range1.contains(3)) throw AssertionError() + if (!(3 !in objectArray.indices) != range1.contains(3)) throw AssertionError() // no local optimizations if (element18 in objectArray.indices != range1.contains(element18)) throw AssertionError() if (element18 !in objectArray.indices != !range1.contains(element18)) throw AssertionError() @@ -914,10 +698,10 @@ fun testR1xE18() { fun testR1xE19() { // with possible local optimizations - if (2.toShort() in objectArray.indices != range1.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in objectArray.indices != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in objectArray.indices) != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in objectArray.indices) != range1.contains(2.toShort())) throw AssertionError() + if (3.toLong() in objectArray.indices != range1.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in objectArray.indices != !range1.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in objectArray.indices) != !range1.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in objectArray.indices) != range1.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in objectArray.indices != range1.contains(element19)) throw AssertionError() if (element19 !in objectArray.indices != !range1.contains(element19)) throw AssertionError() @@ -927,10 +711,10 @@ fun testR1xE19() { fun testR1xE20() { // with possible local optimizations - if (2 in objectArray.indices != range1.contains(2)) throw AssertionError() - if (2 !in objectArray.indices != !range1.contains(2)) throw AssertionError() - if (!(2 in objectArray.indices) != !range1.contains(2)) throw AssertionError() - if (!(2 !in objectArray.indices) != range1.contains(2)) throw AssertionError() + if (4.toByte() in objectArray.indices != range1.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in objectArray.indices != !range1.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in objectArray.indices) != !range1.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in objectArray.indices) != range1.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in objectArray.indices != range1.contains(element20)) throw AssertionError() if (element20 !in objectArray.indices != !range1.contains(element20)) throw AssertionError() @@ -940,10 +724,10 @@ fun testR1xE20() { fun testR1xE21() { // with possible local optimizations - if (2.toLong() in objectArray.indices != range1.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in objectArray.indices != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in objectArray.indices) != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in objectArray.indices) != range1.contains(2.toLong())) throw AssertionError() + if (4.toShort() in objectArray.indices != range1.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in objectArray.indices != !range1.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in objectArray.indices) != !range1.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in objectArray.indices) != range1.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in objectArray.indices != range1.contains(element21)) throw AssertionError() if (element21 !in objectArray.indices != !range1.contains(element21)) throw AssertionError() @@ -953,10 +737,10 @@ fun testR1xE21() { fun testR1xE22() { // with possible local optimizations - if (2.toFloat() in objectArray.indices != range1.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in objectArray.indices != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in objectArray.indices) != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in objectArray.indices) != range1.contains(2.toFloat())) throw AssertionError() + if (4 in objectArray.indices != range1.contains(4)) throw AssertionError() + if (4 !in objectArray.indices != !range1.contains(4)) throw AssertionError() + if (!(4 in objectArray.indices) != !range1.contains(4)) throw AssertionError() + if (!(4 !in objectArray.indices) != range1.contains(4)) throw AssertionError() // no local optimizations if (element22 in objectArray.indices != range1.contains(element22)) throw AssertionError() if (element22 !in objectArray.indices != !range1.contains(element22)) throw AssertionError() @@ -965,172 +749,16 @@ fun testR1xE22() { } fun testR1xE23() { - // with possible local optimizations - if (2.toDouble() in objectArray.indices != range1.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in objectArray.indices != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in objectArray.indices) != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in objectArray.indices) != range1.contains(2.toDouble())) throw AssertionError() - // no local optimizations - if (element23 in objectArray.indices != range1.contains(element23)) throw AssertionError() - if (element23 !in objectArray.indices != !range1.contains(element23)) throw AssertionError() - if (!(element23 in objectArray.indices) != !range1.contains(element23)) throw AssertionError() - if (!(element23 !in objectArray.indices) != range1.contains(element23)) throw AssertionError() -} - -fun testR1xE24() { - // with possible local optimizations - if (3.toByte() in objectArray.indices != range1.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in objectArray.indices != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in objectArray.indices) != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in objectArray.indices) != range1.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in objectArray.indices != range1.contains(element24)) throw AssertionError() - if (element24 !in objectArray.indices != !range1.contains(element24)) throw AssertionError() - if (!(element24 in objectArray.indices) != !range1.contains(element24)) throw AssertionError() - if (!(element24 !in objectArray.indices) != range1.contains(element24)) throw AssertionError() -} - -fun testR1xE25() { - // with possible local optimizations - if (3.toShort() in objectArray.indices != range1.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in objectArray.indices != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in objectArray.indices) != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in objectArray.indices) != range1.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in objectArray.indices != range1.contains(element25)) throw AssertionError() - if (element25 !in objectArray.indices != !range1.contains(element25)) throw AssertionError() - if (!(element25 in objectArray.indices) != !range1.contains(element25)) throw AssertionError() - if (!(element25 !in objectArray.indices) != range1.contains(element25)) throw AssertionError() -} - -fun testR1xE26() { - // with possible local optimizations - if (3 in objectArray.indices != range1.contains(3)) throw AssertionError() - if (3 !in objectArray.indices != !range1.contains(3)) throw AssertionError() - if (!(3 in objectArray.indices) != !range1.contains(3)) throw AssertionError() - if (!(3 !in objectArray.indices) != range1.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in objectArray.indices != range1.contains(element26)) throw AssertionError() - if (element26 !in objectArray.indices != !range1.contains(element26)) throw AssertionError() - if (!(element26 in objectArray.indices) != !range1.contains(element26)) throw AssertionError() - if (!(element26 !in objectArray.indices) != range1.contains(element26)) throw AssertionError() -} - -fun testR1xE27() { - // with possible local optimizations - if (3.toLong() in objectArray.indices != range1.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in objectArray.indices != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in objectArray.indices) != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in objectArray.indices) != range1.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in objectArray.indices != range1.contains(element27)) throw AssertionError() - if (element27 !in objectArray.indices != !range1.contains(element27)) throw AssertionError() - if (!(element27 in objectArray.indices) != !range1.contains(element27)) throw AssertionError() - if (!(element27 !in objectArray.indices) != range1.contains(element27)) throw AssertionError() -} - -fun testR1xE28() { - // with possible local optimizations - if (3.toFloat() in objectArray.indices != range1.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in objectArray.indices != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in objectArray.indices) != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in objectArray.indices) != range1.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in objectArray.indices != range1.contains(element28)) throw AssertionError() - if (element28 !in objectArray.indices != !range1.contains(element28)) throw AssertionError() - if (!(element28 in objectArray.indices) != !range1.contains(element28)) throw AssertionError() - if (!(element28 !in objectArray.indices) != range1.contains(element28)) throw AssertionError() -} - -fun testR1xE29() { - // with possible local optimizations - if (3.toDouble() in objectArray.indices != range1.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in objectArray.indices != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in objectArray.indices) != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in objectArray.indices) != range1.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in objectArray.indices != range1.contains(element29)) throw AssertionError() - if (element29 !in objectArray.indices != !range1.contains(element29)) throw AssertionError() - if (!(element29 in objectArray.indices) != !range1.contains(element29)) throw AssertionError() - if (!(element29 !in objectArray.indices) != range1.contains(element29)) throw AssertionError() -} - -fun testR1xE30() { - // with possible local optimizations - if (4.toByte() in objectArray.indices != range1.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in objectArray.indices != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in objectArray.indices) != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in objectArray.indices) != range1.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in objectArray.indices != range1.contains(element30)) throw AssertionError() - if (element30 !in objectArray.indices != !range1.contains(element30)) throw AssertionError() - if (!(element30 in objectArray.indices) != !range1.contains(element30)) throw AssertionError() - if (!(element30 !in objectArray.indices) != range1.contains(element30)) throw AssertionError() -} - -fun testR1xE31() { - // with possible local optimizations - if (4.toShort() in objectArray.indices != range1.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in objectArray.indices != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in objectArray.indices) != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in objectArray.indices) != range1.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in objectArray.indices != range1.contains(element31)) throw AssertionError() - if (element31 !in objectArray.indices != !range1.contains(element31)) throw AssertionError() - if (!(element31 in objectArray.indices) != !range1.contains(element31)) throw AssertionError() - if (!(element31 !in objectArray.indices) != range1.contains(element31)) throw AssertionError() -} - -fun testR1xE32() { - // with possible local optimizations - if (4 in objectArray.indices != range1.contains(4)) throw AssertionError() - if (4 !in objectArray.indices != !range1.contains(4)) throw AssertionError() - if (!(4 in objectArray.indices) != !range1.contains(4)) throw AssertionError() - if (!(4 !in objectArray.indices) != range1.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in objectArray.indices != range1.contains(element32)) throw AssertionError() - if (element32 !in objectArray.indices != !range1.contains(element32)) throw AssertionError() - if (!(element32 in objectArray.indices) != !range1.contains(element32)) throw AssertionError() - if (!(element32 !in objectArray.indices) != range1.contains(element32)) throw AssertionError() -} - -fun testR1xE33() { // with possible local optimizations if (4.toLong() in objectArray.indices != range1.contains(4.toLong())) throw AssertionError() if (4.toLong() !in objectArray.indices != !range1.contains(4.toLong())) throw AssertionError() if (!(4.toLong() in objectArray.indices) != !range1.contains(4.toLong())) throw AssertionError() if (!(4.toLong() !in objectArray.indices) != range1.contains(4.toLong())) throw AssertionError() // no local optimizations - if (element33 in objectArray.indices != range1.contains(element33)) throw AssertionError() - if (element33 !in objectArray.indices != !range1.contains(element33)) throw AssertionError() - if (!(element33 in objectArray.indices) != !range1.contains(element33)) throw AssertionError() - if (!(element33 !in objectArray.indices) != range1.contains(element33)) throw AssertionError() -} - -fun testR1xE34() { - // with possible local optimizations - if (4.toFloat() in objectArray.indices != range1.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in objectArray.indices != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in objectArray.indices) != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in objectArray.indices) != range1.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in objectArray.indices != range1.contains(element34)) throw AssertionError() - if (element34 !in objectArray.indices != !range1.contains(element34)) throw AssertionError() - if (!(element34 in objectArray.indices) != !range1.contains(element34)) throw AssertionError() - if (!(element34 !in objectArray.indices) != range1.contains(element34)) throw AssertionError() -} - -fun testR1xE35() { - // with possible local optimizations - if (4.toDouble() in objectArray.indices != range1.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in objectArray.indices != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in objectArray.indices) != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in objectArray.indices) != range1.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in objectArray.indices != range1.contains(element35)) throw AssertionError() - if (element35 !in objectArray.indices != !range1.contains(element35)) throw AssertionError() - if (!(element35 in objectArray.indices) != !range1.contains(element35)) throw AssertionError() - if (!(element35 !in objectArray.indices) != range1.contains(element35)) throw AssertionError() + if (element23 in objectArray.indices != range1.contains(element23)) throw AssertionError() + if (element23 !in objectArray.indices != !range1.contains(element23)) throw AssertionError() + if (!(element23 in objectArray.indices) != !range1.contains(element23)) throw AssertionError() + if (!(element23 !in objectArray.indices) != range1.contains(element23)) throw AssertionError() } fun testR2xE0() { @@ -1187,10 +815,10 @@ fun testR2xE3() { fun testR2xE4() { // with possible local optimizations - if ((-1).toFloat() in emptyIntArray.indices != range2.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in emptyIntArray.indices != !range2.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in emptyIntArray.indices) != !range2.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in emptyIntArray.indices) != range2.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in emptyIntArray.indices != range2.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in emptyIntArray.indices != !range2.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in emptyIntArray.indices) != !range2.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in emptyIntArray.indices) != range2.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in emptyIntArray.indices != range2.contains(element4)) throw AssertionError() if (element4 !in emptyIntArray.indices != !range2.contains(element4)) throw AssertionError() @@ -1200,10 +828,10 @@ fun testR2xE4() { fun testR2xE5() { // with possible local optimizations - if ((-1).toDouble() in emptyIntArray.indices != range2.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in emptyIntArray.indices != !range2.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in emptyIntArray.indices) != !range2.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in emptyIntArray.indices) != range2.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in emptyIntArray.indices != range2.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in emptyIntArray.indices != !range2.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in emptyIntArray.indices) != !range2.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in emptyIntArray.indices) != range2.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in emptyIntArray.indices != range2.contains(element5)) throw AssertionError() if (element5 !in emptyIntArray.indices != !range2.contains(element5)) throw AssertionError() @@ -1213,10 +841,10 @@ fun testR2xE5() { fun testR2xE6() { // with possible local optimizations - if (0.toByte() in emptyIntArray.indices != range2.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in emptyIntArray.indices != !range2.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in emptyIntArray.indices) != !range2.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in emptyIntArray.indices) != range2.contains(0.toByte())) throw AssertionError() + if (0 in emptyIntArray.indices != range2.contains(0)) throw AssertionError() + if (0 !in emptyIntArray.indices != !range2.contains(0)) throw AssertionError() + if (!(0 in emptyIntArray.indices) != !range2.contains(0)) throw AssertionError() + if (!(0 !in emptyIntArray.indices) != range2.contains(0)) throw AssertionError() // no local optimizations if (element6 in emptyIntArray.indices != range2.contains(element6)) throw AssertionError() if (element6 !in emptyIntArray.indices != !range2.contains(element6)) throw AssertionError() @@ -1226,10 +854,10 @@ fun testR2xE6() { fun testR2xE7() { // with possible local optimizations - if (0.toShort() in emptyIntArray.indices != range2.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in emptyIntArray.indices != !range2.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in emptyIntArray.indices) != !range2.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in emptyIntArray.indices) != range2.contains(0.toShort())) throw AssertionError() + if (0.toLong() in emptyIntArray.indices != range2.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in emptyIntArray.indices != !range2.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in emptyIntArray.indices) != !range2.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in emptyIntArray.indices) != range2.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in emptyIntArray.indices != range2.contains(element7)) throw AssertionError() if (element7 !in emptyIntArray.indices != !range2.contains(element7)) throw AssertionError() @@ -1239,10 +867,10 @@ fun testR2xE7() { fun testR2xE8() { // with possible local optimizations - if (0 in emptyIntArray.indices != range2.contains(0)) throw AssertionError() - if (0 !in emptyIntArray.indices != !range2.contains(0)) throw AssertionError() - if (!(0 in emptyIntArray.indices) != !range2.contains(0)) throw AssertionError() - if (!(0 !in emptyIntArray.indices) != range2.contains(0)) throw AssertionError() + if (1.toByte() in emptyIntArray.indices != range2.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in emptyIntArray.indices != !range2.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in emptyIntArray.indices) != !range2.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in emptyIntArray.indices) != range2.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in emptyIntArray.indices != range2.contains(element8)) throw AssertionError() if (element8 !in emptyIntArray.indices != !range2.contains(element8)) throw AssertionError() @@ -1252,10 +880,10 @@ fun testR2xE8() { fun testR2xE9() { // with possible local optimizations - if (0.toLong() in emptyIntArray.indices != range2.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in emptyIntArray.indices != !range2.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in emptyIntArray.indices) != !range2.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in emptyIntArray.indices) != range2.contains(0.toLong())) throw AssertionError() + if (1.toShort() in emptyIntArray.indices != range2.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in emptyIntArray.indices != !range2.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in emptyIntArray.indices) != !range2.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in emptyIntArray.indices) != range2.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in emptyIntArray.indices != range2.contains(element9)) throw AssertionError() if (element9 !in emptyIntArray.indices != !range2.contains(element9)) throw AssertionError() @@ -1265,10 +893,10 @@ fun testR2xE9() { fun testR2xE10() { // with possible local optimizations - if (0.toFloat() in emptyIntArray.indices != range2.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in emptyIntArray.indices != !range2.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in emptyIntArray.indices) != !range2.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in emptyIntArray.indices) != range2.contains(0.toFloat())) throw AssertionError() + if (1 in emptyIntArray.indices != range2.contains(1)) throw AssertionError() + if (1 !in emptyIntArray.indices != !range2.contains(1)) throw AssertionError() + if (!(1 in emptyIntArray.indices) != !range2.contains(1)) throw AssertionError() + if (!(1 !in emptyIntArray.indices) != range2.contains(1)) throw AssertionError() // no local optimizations if (element10 in emptyIntArray.indices != range2.contains(element10)) throw AssertionError() if (element10 !in emptyIntArray.indices != !range2.contains(element10)) throw AssertionError() @@ -1278,10 +906,10 @@ fun testR2xE10() { fun testR2xE11() { // with possible local optimizations - if (0.toDouble() in emptyIntArray.indices != range2.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in emptyIntArray.indices != !range2.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in emptyIntArray.indices) != !range2.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in emptyIntArray.indices) != range2.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in emptyIntArray.indices != range2.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in emptyIntArray.indices != !range2.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in emptyIntArray.indices) != !range2.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in emptyIntArray.indices) != range2.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in emptyIntArray.indices != range2.contains(element11)) throw AssertionError() if (element11 !in emptyIntArray.indices != !range2.contains(element11)) throw AssertionError() @@ -1291,10 +919,10 @@ fun testR2xE11() { fun testR2xE12() { // with possible local optimizations - if (1.toByte() in emptyIntArray.indices != range2.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in emptyIntArray.indices != !range2.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in emptyIntArray.indices) != !range2.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in emptyIntArray.indices) != range2.contains(1.toByte())) throw AssertionError() + if (2.toByte() in emptyIntArray.indices != range2.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in emptyIntArray.indices != !range2.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in emptyIntArray.indices) != !range2.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in emptyIntArray.indices) != range2.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in emptyIntArray.indices != range2.contains(element12)) throw AssertionError() if (element12 !in emptyIntArray.indices != !range2.contains(element12)) throw AssertionError() @@ -1304,10 +932,10 @@ fun testR2xE12() { fun testR2xE13() { // with possible local optimizations - if (1.toShort() in emptyIntArray.indices != range2.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in emptyIntArray.indices != !range2.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in emptyIntArray.indices) != !range2.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in emptyIntArray.indices) != range2.contains(1.toShort())) throw AssertionError() + if (2.toShort() in emptyIntArray.indices != range2.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in emptyIntArray.indices != !range2.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in emptyIntArray.indices) != !range2.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in emptyIntArray.indices) != range2.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in emptyIntArray.indices != range2.contains(element13)) throw AssertionError() if (element13 !in emptyIntArray.indices != !range2.contains(element13)) throw AssertionError() @@ -1317,10 +945,10 @@ fun testR2xE13() { fun testR2xE14() { // with possible local optimizations - if (1 in emptyIntArray.indices != range2.contains(1)) throw AssertionError() - if (1 !in emptyIntArray.indices != !range2.contains(1)) throw AssertionError() - if (!(1 in emptyIntArray.indices) != !range2.contains(1)) throw AssertionError() - if (!(1 !in emptyIntArray.indices) != range2.contains(1)) throw AssertionError() + if (2 in emptyIntArray.indices != range2.contains(2)) throw AssertionError() + if (2 !in emptyIntArray.indices != !range2.contains(2)) throw AssertionError() + if (!(2 in emptyIntArray.indices) != !range2.contains(2)) throw AssertionError() + if (!(2 !in emptyIntArray.indices) != range2.contains(2)) throw AssertionError() // no local optimizations if (element14 in emptyIntArray.indices != range2.contains(element14)) throw AssertionError() if (element14 !in emptyIntArray.indices != !range2.contains(element14)) throw AssertionError() @@ -1330,10 +958,10 @@ fun testR2xE14() { fun testR2xE15() { // with possible local optimizations - if (1.toLong() in emptyIntArray.indices != range2.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in emptyIntArray.indices != !range2.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in emptyIntArray.indices) != !range2.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in emptyIntArray.indices) != range2.contains(1.toLong())) throw AssertionError() + if (2.toLong() in emptyIntArray.indices != range2.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in emptyIntArray.indices != !range2.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in emptyIntArray.indices) != !range2.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in emptyIntArray.indices) != range2.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in emptyIntArray.indices != range2.contains(element15)) throw AssertionError() if (element15 !in emptyIntArray.indices != !range2.contains(element15)) throw AssertionError() @@ -1343,10 +971,10 @@ fun testR2xE15() { fun testR2xE16() { // with possible local optimizations - if (1.toFloat() in emptyIntArray.indices != range2.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in emptyIntArray.indices != !range2.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in emptyIntArray.indices) != !range2.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in emptyIntArray.indices) != range2.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in emptyIntArray.indices != range2.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in emptyIntArray.indices != !range2.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in emptyIntArray.indices) != !range2.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in emptyIntArray.indices) != range2.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in emptyIntArray.indices != range2.contains(element16)) throw AssertionError() if (element16 !in emptyIntArray.indices != !range2.contains(element16)) throw AssertionError() @@ -1356,10 +984,10 @@ fun testR2xE16() { fun testR2xE17() { // with possible local optimizations - if (1.toDouble() in emptyIntArray.indices != range2.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in emptyIntArray.indices != !range2.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in emptyIntArray.indices) != !range2.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in emptyIntArray.indices) != range2.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in emptyIntArray.indices != range2.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in emptyIntArray.indices != !range2.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in emptyIntArray.indices) != !range2.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in emptyIntArray.indices) != range2.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in emptyIntArray.indices != range2.contains(element17)) throw AssertionError() if (element17 !in emptyIntArray.indices != !range2.contains(element17)) throw AssertionError() @@ -1369,10 +997,10 @@ fun testR2xE17() { fun testR2xE18() { // with possible local optimizations - if (2.toByte() in emptyIntArray.indices != range2.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in emptyIntArray.indices != !range2.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in emptyIntArray.indices) != !range2.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in emptyIntArray.indices) != range2.contains(2.toByte())) throw AssertionError() + if (3 in emptyIntArray.indices != range2.contains(3)) throw AssertionError() + if (3 !in emptyIntArray.indices != !range2.contains(3)) throw AssertionError() + if (!(3 in emptyIntArray.indices) != !range2.contains(3)) throw AssertionError() + if (!(3 !in emptyIntArray.indices) != range2.contains(3)) throw AssertionError() // no local optimizations if (element18 in emptyIntArray.indices != range2.contains(element18)) throw AssertionError() if (element18 !in emptyIntArray.indices != !range2.contains(element18)) throw AssertionError() @@ -1382,10 +1010,10 @@ fun testR2xE18() { fun testR2xE19() { // with possible local optimizations - if (2.toShort() in emptyIntArray.indices != range2.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in emptyIntArray.indices != !range2.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in emptyIntArray.indices) != !range2.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in emptyIntArray.indices) != range2.contains(2.toShort())) throw AssertionError() + if (3.toLong() in emptyIntArray.indices != range2.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in emptyIntArray.indices != !range2.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in emptyIntArray.indices) != !range2.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in emptyIntArray.indices) != range2.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in emptyIntArray.indices != range2.contains(element19)) throw AssertionError() if (element19 !in emptyIntArray.indices != !range2.contains(element19)) throw AssertionError() @@ -1395,10 +1023,10 @@ fun testR2xE19() { fun testR2xE20() { // with possible local optimizations - if (2 in emptyIntArray.indices != range2.contains(2)) throw AssertionError() - if (2 !in emptyIntArray.indices != !range2.contains(2)) throw AssertionError() - if (!(2 in emptyIntArray.indices) != !range2.contains(2)) throw AssertionError() - if (!(2 !in emptyIntArray.indices) != range2.contains(2)) throw AssertionError() + if (4.toByte() in emptyIntArray.indices != range2.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in emptyIntArray.indices != !range2.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in emptyIntArray.indices) != !range2.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in emptyIntArray.indices) != range2.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in emptyIntArray.indices != range2.contains(element20)) throw AssertionError() if (element20 !in emptyIntArray.indices != !range2.contains(element20)) throw AssertionError() @@ -1408,10 +1036,10 @@ fun testR2xE20() { fun testR2xE21() { // with possible local optimizations - if (2.toLong() in emptyIntArray.indices != range2.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in emptyIntArray.indices != !range2.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in emptyIntArray.indices) != !range2.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in emptyIntArray.indices) != range2.contains(2.toLong())) throw AssertionError() + if (4.toShort() in emptyIntArray.indices != range2.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in emptyIntArray.indices != !range2.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in emptyIntArray.indices) != !range2.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in emptyIntArray.indices) != range2.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in emptyIntArray.indices != range2.contains(element21)) throw AssertionError() if (element21 !in emptyIntArray.indices != !range2.contains(element21)) throw AssertionError() @@ -1421,10 +1049,10 @@ fun testR2xE21() { fun testR2xE22() { // with possible local optimizations - if (2.toFloat() in emptyIntArray.indices != range2.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in emptyIntArray.indices != !range2.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in emptyIntArray.indices) != !range2.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in emptyIntArray.indices) != range2.contains(2.toFloat())) throw AssertionError() + if (4 in emptyIntArray.indices != range2.contains(4)) throw AssertionError() + if (4 !in emptyIntArray.indices != !range2.contains(4)) throw AssertionError() + if (!(4 in emptyIntArray.indices) != !range2.contains(4)) throw AssertionError() + if (!(4 !in emptyIntArray.indices) != range2.contains(4)) throw AssertionError() // no local optimizations if (element22 in emptyIntArray.indices != range2.contains(element22)) throw AssertionError() if (element22 !in emptyIntArray.indices != !range2.contains(element22)) throw AssertionError() @@ -1433,172 +1061,16 @@ fun testR2xE22() { } fun testR2xE23() { - // with possible local optimizations - if (2.toDouble() in emptyIntArray.indices != range2.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in emptyIntArray.indices != !range2.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in emptyIntArray.indices) != !range2.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in emptyIntArray.indices) != range2.contains(2.toDouble())) throw AssertionError() - // no local optimizations - if (element23 in emptyIntArray.indices != range2.contains(element23)) throw AssertionError() - if (element23 !in emptyIntArray.indices != !range2.contains(element23)) throw AssertionError() - if (!(element23 in emptyIntArray.indices) != !range2.contains(element23)) throw AssertionError() - if (!(element23 !in emptyIntArray.indices) != range2.contains(element23)) throw AssertionError() -} - -fun testR2xE24() { - // with possible local optimizations - if (3.toByte() in emptyIntArray.indices != range2.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in emptyIntArray.indices != !range2.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in emptyIntArray.indices) != !range2.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in emptyIntArray.indices) != range2.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in emptyIntArray.indices != range2.contains(element24)) throw AssertionError() - if (element24 !in emptyIntArray.indices != !range2.contains(element24)) throw AssertionError() - if (!(element24 in emptyIntArray.indices) != !range2.contains(element24)) throw AssertionError() - if (!(element24 !in emptyIntArray.indices) != range2.contains(element24)) throw AssertionError() -} - -fun testR2xE25() { - // with possible local optimizations - if (3.toShort() in emptyIntArray.indices != range2.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in emptyIntArray.indices != !range2.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in emptyIntArray.indices) != !range2.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in emptyIntArray.indices) != range2.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in emptyIntArray.indices != range2.contains(element25)) throw AssertionError() - if (element25 !in emptyIntArray.indices != !range2.contains(element25)) throw AssertionError() - if (!(element25 in emptyIntArray.indices) != !range2.contains(element25)) throw AssertionError() - if (!(element25 !in emptyIntArray.indices) != range2.contains(element25)) throw AssertionError() -} - -fun testR2xE26() { - // with possible local optimizations - if (3 in emptyIntArray.indices != range2.contains(3)) throw AssertionError() - if (3 !in emptyIntArray.indices != !range2.contains(3)) throw AssertionError() - if (!(3 in emptyIntArray.indices) != !range2.contains(3)) throw AssertionError() - if (!(3 !in emptyIntArray.indices) != range2.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in emptyIntArray.indices != range2.contains(element26)) throw AssertionError() - if (element26 !in emptyIntArray.indices != !range2.contains(element26)) throw AssertionError() - if (!(element26 in emptyIntArray.indices) != !range2.contains(element26)) throw AssertionError() - if (!(element26 !in emptyIntArray.indices) != range2.contains(element26)) throw AssertionError() -} - -fun testR2xE27() { - // with possible local optimizations - if (3.toLong() in emptyIntArray.indices != range2.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in emptyIntArray.indices != !range2.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in emptyIntArray.indices) != !range2.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in emptyIntArray.indices) != range2.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in emptyIntArray.indices != range2.contains(element27)) throw AssertionError() - if (element27 !in emptyIntArray.indices != !range2.contains(element27)) throw AssertionError() - if (!(element27 in emptyIntArray.indices) != !range2.contains(element27)) throw AssertionError() - if (!(element27 !in emptyIntArray.indices) != range2.contains(element27)) throw AssertionError() -} - -fun testR2xE28() { - // with possible local optimizations - if (3.toFloat() in emptyIntArray.indices != range2.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in emptyIntArray.indices != !range2.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in emptyIntArray.indices) != !range2.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in emptyIntArray.indices) != range2.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in emptyIntArray.indices != range2.contains(element28)) throw AssertionError() - if (element28 !in emptyIntArray.indices != !range2.contains(element28)) throw AssertionError() - if (!(element28 in emptyIntArray.indices) != !range2.contains(element28)) throw AssertionError() - if (!(element28 !in emptyIntArray.indices) != range2.contains(element28)) throw AssertionError() -} - -fun testR2xE29() { - // with possible local optimizations - if (3.toDouble() in emptyIntArray.indices != range2.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in emptyIntArray.indices != !range2.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in emptyIntArray.indices) != !range2.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in emptyIntArray.indices) != range2.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in emptyIntArray.indices != range2.contains(element29)) throw AssertionError() - if (element29 !in emptyIntArray.indices != !range2.contains(element29)) throw AssertionError() - if (!(element29 in emptyIntArray.indices) != !range2.contains(element29)) throw AssertionError() - if (!(element29 !in emptyIntArray.indices) != range2.contains(element29)) throw AssertionError() -} - -fun testR2xE30() { - // with possible local optimizations - if (4.toByte() in emptyIntArray.indices != range2.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in emptyIntArray.indices != !range2.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in emptyIntArray.indices) != !range2.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in emptyIntArray.indices) != range2.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in emptyIntArray.indices != range2.contains(element30)) throw AssertionError() - if (element30 !in emptyIntArray.indices != !range2.contains(element30)) throw AssertionError() - if (!(element30 in emptyIntArray.indices) != !range2.contains(element30)) throw AssertionError() - if (!(element30 !in emptyIntArray.indices) != range2.contains(element30)) throw AssertionError() -} - -fun testR2xE31() { - // with possible local optimizations - if (4.toShort() in emptyIntArray.indices != range2.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in emptyIntArray.indices != !range2.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in emptyIntArray.indices) != !range2.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in emptyIntArray.indices) != range2.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in emptyIntArray.indices != range2.contains(element31)) throw AssertionError() - if (element31 !in emptyIntArray.indices != !range2.contains(element31)) throw AssertionError() - if (!(element31 in emptyIntArray.indices) != !range2.contains(element31)) throw AssertionError() - if (!(element31 !in emptyIntArray.indices) != range2.contains(element31)) throw AssertionError() -} - -fun testR2xE32() { - // with possible local optimizations - if (4 in emptyIntArray.indices != range2.contains(4)) throw AssertionError() - if (4 !in emptyIntArray.indices != !range2.contains(4)) throw AssertionError() - if (!(4 in emptyIntArray.indices) != !range2.contains(4)) throw AssertionError() - if (!(4 !in emptyIntArray.indices) != range2.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in emptyIntArray.indices != range2.contains(element32)) throw AssertionError() - if (element32 !in emptyIntArray.indices != !range2.contains(element32)) throw AssertionError() - if (!(element32 in emptyIntArray.indices) != !range2.contains(element32)) throw AssertionError() - if (!(element32 !in emptyIntArray.indices) != range2.contains(element32)) throw AssertionError() -} - -fun testR2xE33() { // with possible local optimizations if (4.toLong() in emptyIntArray.indices != range2.contains(4.toLong())) throw AssertionError() if (4.toLong() !in emptyIntArray.indices != !range2.contains(4.toLong())) throw AssertionError() if (!(4.toLong() in emptyIntArray.indices) != !range2.contains(4.toLong())) throw AssertionError() if (!(4.toLong() !in emptyIntArray.indices) != range2.contains(4.toLong())) throw AssertionError() // no local optimizations - if (element33 in emptyIntArray.indices != range2.contains(element33)) throw AssertionError() - if (element33 !in emptyIntArray.indices != !range2.contains(element33)) throw AssertionError() - if (!(element33 in emptyIntArray.indices) != !range2.contains(element33)) throw AssertionError() - if (!(element33 !in emptyIntArray.indices) != range2.contains(element33)) throw AssertionError() -} - -fun testR2xE34() { - // with possible local optimizations - if (4.toFloat() in emptyIntArray.indices != range2.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in emptyIntArray.indices != !range2.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in emptyIntArray.indices) != !range2.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in emptyIntArray.indices) != range2.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in emptyIntArray.indices != range2.contains(element34)) throw AssertionError() - if (element34 !in emptyIntArray.indices != !range2.contains(element34)) throw AssertionError() - if (!(element34 in emptyIntArray.indices) != !range2.contains(element34)) throw AssertionError() - if (!(element34 !in emptyIntArray.indices) != range2.contains(element34)) throw AssertionError() -} - -fun testR2xE35() { - // with possible local optimizations - if (4.toDouble() in emptyIntArray.indices != range2.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in emptyIntArray.indices != !range2.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in emptyIntArray.indices) != !range2.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in emptyIntArray.indices) != range2.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in emptyIntArray.indices != range2.contains(element35)) throw AssertionError() - if (element35 !in emptyIntArray.indices != !range2.contains(element35)) throw AssertionError() - if (!(element35 in emptyIntArray.indices) != !range2.contains(element35)) throw AssertionError() - if (!(element35 !in emptyIntArray.indices) != range2.contains(element35)) throw AssertionError() + if (element23 in emptyIntArray.indices != range2.contains(element23)) throw AssertionError() + if (element23 !in emptyIntArray.indices != !range2.contains(element23)) throw AssertionError() + if (!(element23 in emptyIntArray.indices) != !range2.contains(element23)) throw AssertionError() + if (!(element23 !in emptyIntArray.indices) != range2.contains(element23)) throw AssertionError() } fun testR3xE0() { @@ -1655,10 +1127,10 @@ fun testR3xE3() { fun testR3xE4() { // with possible local optimizations - if ((-1).toFloat() in emptyObjectArray.indices != range3.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in emptyObjectArray.indices != !range3.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in emptyObjectArray.indices) != !range3.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in emptyObjectArray.indices) != range3.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in emptyObjectArray.indices != range3.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in emptyObjectArray.indices != !range3.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in emptyObjectArray.indices) != !range3.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in emptyObjectArray.indices) != range3.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in emptyObjectArray.indices != range3.contains(element4)) throw AssertionError() if (element4 !in emptyObjectArray.indices != !range3.contains(element4)) throw AssertionError() @@ -1668,10 +1140,10 @@ fun testR3xE4() { fun testR3xE5() { // with possible local optimizations - if ((-1).toDouble() in emptyObjectArray.indices != range3.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in emptyObjectArray.indices != !range3.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in emptyObjectArray.indices) != !range3.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in emptyObjectArray.indices) != range3.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in emptyObjectArray.indices != range3.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in emptyObjectArray.indices != !range3.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in emptyObjectArray.indices) != !range3.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in emptyObjectArray.indices) != range3.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in emptyObjectArray.indices != range3.contains(element5)) throw AssertionError() if (element5 !in emptyObjectArray.indices != !range3.contains(element5)) throw AssertionError() @@ -1681,10 +1153,10 @@ fun testR3xE5() { fun testR3xE6() { // with possible local optimizations - if (0.toByte() in emptyObjectArray.indices != range3.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in emptyObjectArray.indices != !range3.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in emptyObjectArray.indices) != !range3.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in emptyObjectArray.indices) != range3.contains(0.toByte())) throw AssertionError() + if (0 in emptyObjectArray.indices != range3.contains(0)) throw AssertionError() + if (0 !in emptyObjectArray.indices != !range3.contains(0)) throw AssertionError() + if (!(0 in emptyObjectArray.indices) != !range3.contains(0)) throw AssertionError() + if (!(0 !in emptyObjectArray.indices) != range3.contains(0)) throw AssertionError() // no local optimizations if (element6 in emptyObjectArray.indices != range3.contains(element6)) throw AssertionError() if (element6 !in emptyObjectArray.indices != !range3.contains(element6)) throw AssertionError() @@ -1694,10 +1166,10 @@ fun testR3xE6() { fun testR3xE7() { // with possible local optimizations - if (0.toShort() in emptyObjectArray.indices != range3.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in emptyObjectArray.indices != !range3.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in emptyObjectArray.indices) != !range3.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in emptyObjectArray.indices) != range3.contains(0.toShort())) throw AssertionError() + if (0.toLong() in emptyObjectArray.indices != range3.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in emptyObjectArray.indices != !range3.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in emptyObjectArray.indices) != !range3.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in emptyObjectArray.indices) != range3.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in emptyObjectArray.indices != range3.contains(element7)) throw AssertionError() if (element7 !in emptyObjectArray.indices != !range3.contains(element7)) throw AssertionError() @@ -1707,10 +1179,10 @@ fun testR3xE7() { fun testR3xE8() { // with possible local optimizations - if (0 in emptyObjectArray.indices != range3.contains(0)) throw AssertionError() - if (0 !in emptyObjectArray.indices != !range3.contains(0)) throw AssertionError() - if (!(0 in emptyObjectArray.indices) != !range3.contains(0)) throw AssertionError() - if (!(0 !in emptyObjectArray.indices) != range3.contains(0)) throw AssertionError() + if (1.toByte() in emptyObjectArray.indices != range3.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in emptyObjectArray.indices != !range3.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in emptyObjectArray.indices) != !range3.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in emptyObjectArray.indices) != range3.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in emptyObjectArray.indices != range3.contains(element8)) throw AssertionError() if (element8 !in emptyObjectArray.indices != !range3.contains(element8)) throw AssertionError() @@ -1720,10 +1192,10 @@ fun testR3xE8() { fun testR3xE9() { // with possible local optimizations - if (0.toLong() in emptyObjectArray.indices != range3.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in emptyObjectArray.indices != !range3.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in emptyObjectArray.indices) != !range3.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in emptyObjectArray.indices) != range3.contains(0.toLong())) throw AssertionError() + if (1.toShort() in emptyObjectArray.indices != range3.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in emptyObjectArray.indices != !range3.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in emptyObjectArray.indices) != !range3.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in emptyObjectArray.indices) != range3.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in emptyObjectArray.indices != range3.contains(element9)) throw AssertionError() if (element9 !in emptyObjectArray.indices != !range3.contains(element9)) throw AssertionError() @@ -1733,10 +1205,10 @@ fun testR3xE9() { fun testR3xE10() { // with possible local optimizations - if (0.toFloat() in emptyObjectArray.indices != range3.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in emptyObjectArray.indices != !range3.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in emptyObjectArray.indices) != !range3.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in emptyObjectArray.indices) != range3.contains(0.toFloat())) throw AssertionError() + if (1 in emptyObjectArray.indices != range3.contains(1)) throw AssertionError() + if (1 !in emptyObjectArray.indices != !range3.contains(1)) throw AssertionError() + if (!(1 in emptyObjectArray.indices) != !range3.contains(1)) throw AssertionError() + if (!(1 !in emptyObjectArray.indices) != range3.contains(1)) throw AssertionError() // no local optimizations if (element10 in emptyObjectArray.indices != range3.contains(element10)) throw AssertionError() if (element10 !in emptyObjectArray.indices != !range3.contains(element10)) throw AssertionError() @@ -1746,10 +1218,10 @@ fun testR3xE10() { fun testR3xE11() { // with possible local optimizations - if (0.toDouble() in emptyObjectArray.indices != range3.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in emptyObjectArray.indices != !range3.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in emptyObjectArray.indices) != !range3.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in emptyObjectArray.indices) != range3.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in emptyObjectArray.indices != range3.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in emptyObjectArray.indices != !range3.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in emptyObjectArray.indices) != !range3.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in emptyObjectArray.indices) != range3.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in emptyObjectArray.indices != range3.contains(element11)) throw AssertionError() if (element11 !in emptyObjectArray.indices != !range3.contains(element11)) throw AssertionError() @@ -1759,10 +1231,10 @@ fun testR3xE11() { fun testR3xE12() { // with possible local optimizations - if (1.toByte() in emptyObjectArray.indices != range3.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in emptyObjectArray.indices != !range3.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in emptyObjectArray.indices) != !range3.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in emptyObjectArray.indices) != range3.contains(1.toByte())) throw AssertionError() + if (2.toByte() in emptyObjectArray.indices != range3.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in emptyObjectArray.indices != !range3.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in emptyObjectArray.indices) != !range3.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in emptyObjectArray.indices) != range3.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in emptyObjectArray.indices != range3.contains(element12)) throw AssertionError() if (element12 !in emptyObjectArray.indices != !range3.contains(element12)) throw AssertionError() @@ -1772,10 +1244,10 @@ fun testR3xE12() { fun testR3xE13() { // with possible local optimizations - if (1.toShort() in emptyObjectArray.indices != range3.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in emptyObjectArray.indices != !range3.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in emptyObjectArray.indices) != !range3.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in emptyObjectArray.indices) != range3.contains(1.toShort())) throw AssertionError() + if (2.toShort() in emptyObjectArray.indices != range3.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in emptyObjectArray.indices != !range3.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in emptyObjectArray.indices) != !range3.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in emptyObjectArray.indices) != range3.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in emptyObjectArray.indices != range3.contains(element13)) throw AssertionError() if (element13 !in emptyObjectArray.indices != !range3.contains(element13)) throw AssertionError() @@ -1785,10 +1257,10 @@ fun testR3xE13() { fun testR3xE14() { // with possible local optimizations - if (1 in emptyObjectArray.indices != range3.contains(1)) throw AssertionError() - if (1 !in emptyObjectArray.indices != !range3.contains(1)) throw AssertionError() - if (!(1 in emptyObjectArray.indices) != !range3.contains(1)) throw AssertionError() - if (!(1 !in emptyObjectArray.indices) != range3.contains(1)) throw AssertionError() + if (2 in emptyObjectArray.indices != range3.contains(2)) throw AssertionError() + if (2 !in emptyObjectArray.indices != !range3.contains(2)) throw AssertionError() + if (!(2 in emptyObjectArray.indices) != !range3.contains(2)) throw AssertionError() + if (!(2 !in emptyObjectArray.indices) != range3.contains(2)) throw AssertionError() // no local optimizations if (element14 in emptyObjectArray.indices != range3.contains(element14)) throw AssertionError() if (element14 !in emptyObjectArray.indices != !range3.contains(element14)) throw AssertionError() @@ -1798,10 +1270,10 @@ fun testR3xE14() { fun testR3xE15() { // with possible local optimizations - if (1.toLong() in emptyObjectArray.indices != range3.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in emptyObjectArray.indices != !range3.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in emptyObjectArray.indices) != !range3.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in emptyObjectArray.indices) != range3.contains(1.toLong())) throw AssertionError() + if (2.toLong() in emptyObjectArray.indices != range3.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in emptyObjectArray.indices != !range3.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in emptyObjectArray.indices) != !range3.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in emptyObjectArray.indices) != range3.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in emptyObjectArray.indices != range3.contains(element15)) throw AssertionError() if (element15 !in emptyObjectArray.indices != !range3.contains(element15)) throw AssertionError() @@ -1811,10 +1283,10 @@ fun testR3xE15() { fun testR3xE16() { // with possible local optimizations - if (1.toFloat() in emptyObjectArray.indices != range3.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in emptyObjectArray.indices != !range3.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in emptyObjectArray.indices) != !range3.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in emptyObjectArray.indices) != range3.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in emptyObjectArray.indices != range3.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in emptyObjectArray.indices != !range3.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in emptyObjectArray.indices) != !range3.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in emptyObjectArray.indices) != range3.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in emptyObjectArray.indices != range3.contains(element16)) throw AssertionError() if (element16 !in emptyObjectArray.indices != !range3.contains(element16)) throw AssertionError() @@ -1824,10 +1296,10 @@ fun testR3xE16() { fun testR3xE17() { // with possible local optimizations - if (1.toDouble() in emptyObjectArray.indices != range3.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in emptyObjectArray.indices != !range3.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in emptyObjectArray.indices) != !range3.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in emptyObjectArray.indices) != range3.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in emptyObjectArray.indices != range3.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in emptyObjectArray.indices != !range3.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in emptyObjectArray.indices) != !range3.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in emptyObjectArray.indices) != range3.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in emptyObjectArray.indices != range3.contains(element17)) throw AssertionError() if (element17 !in emptyObjectArray.indices != !range3.contains(element17)) throw AssertionError() @@ -1837,10 +1309,10 @@ fun testR3xE17() { fun testR3xE18() { // with possible local optimizations - if (2.toByte() in emptyObjectArray.indices != range3.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in emptyObjectArray.indices != !range3.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in emptyObjectArray.indices) != !range3.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in emptyObjectArray.indices) != range3.contains(2.toByte())) throw AssertionError() + if (3 in emptyObjectArray.indices != range3.contains(3)) throw AssertionError() + if (3 !in emptyObjectArray.indices != !range3.contains(3)) throw AssertionError() + if (!(3 in emptyObjectArray.indices) != !range3.contains(3)) throw AssertionError() + if (!(3 !in emptyObjectArray.indices) != range3.contains(3)) throw AssertionError() // no local optimizations if (element18 in emptyObjectArray.indices != range3.contains(element18)) throw AssertionError() if (element18 !in emptyObjectArray.indices != !range3.contains(element18)) throw AssertionError() @@ -1850,10 +1322,10 @@ fun testR3xE18() { fun testR3xE19() { // with possible local optimizations - if (2.toShort() in emptyObjectArray.indices != range3.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in emptyObjectArray.indices != !range3.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in emptyObjectArray.indices) != !range3.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in emptyObjectArray.indices) != range3.contains(2.toShort())) throw AssertionError() + if (3.toLong() in emptyObjectArray.indices != range3.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in emptyObjectArray.indices != !range3.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in emptyObjectArray.indices) != !range3.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in emptyObjectArray.indices) != range3.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in emptyObjectArray.indices != range3.contains(element19)) throw AssertionError() if (element19 !in emptyObjectArray.indices != !range3.contains(element19)) throw AssertionError() @@ -1863,10 +1335,10 @@ fun testR3xE19() { fun testR3xE20() { // with possible local optimizations - if (2 in emptyObjectArray.indices != range3.contains(2)) throw AssertionError() - if (2 !in emptyObjectArray.indices != !range3.contains(2)) throw AssertionError() - if (!(2 in emptyObjectArray.indices) != !range3.contains(2)) throw AssertionError() - if (!(2 !in emptyObjectArray.indices) != range3.contains(2)) throw AssertionError() + if (4.toByte() in emptyObjectArray.indices != range3.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in emptyObjectArray.indices != !range3.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in emptyObjectArray.indices) != !range3.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in emptyObjectArray.indices) != range3.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in emptyObjectArray.indices != range3.contains(element20)) throw AssertionError() if (element20 !in emptyObjectArray.indices != !range3.contains(element20)) throw AssertionError() @@ -1876,10 +1348,10 @@ fun testR3xE20() { fun testR3xE21() { // with possible local optimizations - if (2.toLong() in emptyObjectArray.indices != range3.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in emptyObjectArray.indices != !range3.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in emptyObjectArray.indices) != !range3.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in emptyObjectArray.indices) != range3.contains(2.toLong())) throw AssertionError() + if (4.toShort() in emptyObjectArray.indices != range3.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in emptyObjectArray.indices != !range3.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in emptyObjectArray.indices) != !range3.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in emptyObjectArray.indices) != range3.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in emptyObjectArray.indices != range3.contains(element21)) throw AssertionError() if (element21 !in emptyObjectArray.indices != !range3.contains(element21)) throw AssertionError() @@ -1889,10 +1361,10 @@ fun testR3xE21() { fun testR3xE22() { // with possible local optimizations - if (2.toFloat() in emptyObjectArray.indices != range3.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in emptyObjectArray.indices != !range3.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in emptyObjectArray.indices) != !range3.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in emptyObjectArray.indices) != range3.contains(2.toFloat())) throw AssertionError() + if (4 in emptyObjectArray.indices != range3.contains(4)) throw AssertionError() + if (4 !in emptyObjectArray.indices != !range3.contains(4)) throw AssertionError() + if (!(4 in emptyObjectArray.indices) != !range3.contains(4)) throw AssertionError() + if (!(4 !in emptyObjectArray.indices) != range3.contains(4)) throw AssertionError() // no local optimizations if (element22 in emptyObjectArray.indices != range3.contains(element22)) throw AssertionError() if (element22 !in emptyObjectArray.indices != !range3.contains(element22)) throw AssertionError() @@ -1902,10 +1374,10 @@ fun testR3xE22() { fun testR3xE23() { // with possible local optimizations - if (2.toDouble() in emptyObjectArray.indices != range3.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in emptyObjectArray.indices != !range3.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in emptyObjectArray.indices) != !range3.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in emptyObjectArray.indices) != range3.contains(2.toDouble())) throw AssertionError() + if (4.toLong() in emptyObjectArray.indices != range3.contains(4.toLong())) throw AssertionError() + if (4.toLong() !in emptyObjectArray.indices != !range3.contains(4.toLong())) throw AssertionError() + if (!(4.toLong() in emptyObjectArray.indices) != !range3.contains(4.toLong())) throw AssertionError() + if (!(4.toLong() !in emptyObjectArray.indices) != range3.contains(4.toLong())) throw AssertionError() // no local optimizations if (element23 in emptyObjectArray.indices != range3.contains(element23)) throw AssertionError() if (element23 !in emptyObjectArray.indices != !range3.contains(element23)) throw AssertionError() @@ -1913,160 +1385,4 @@ fun testR3xE23() { if (!(element23 !in emptyObjectArray.indices) != range3.contains(element23)) throw AssertionError() } -fun testR3xE24() { - // with possible local optimizations - if (3.toByte() in emptyObjectArray.indices != range3.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in emptyObjectArray.indices != !range3.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in emptyObjectArray.indices) != !range3.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in emptyObjectArray.indices) != range3.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in emptyObjectArray.indices != range3.contains(element24)) throw AssertionError() - if (element24 !in emptyObjectArray.indices != !range3.contains(element24)) throw AssertionError() - if (!(element24 in emptyObjectArray.indices) != !range3.contains(element24)) throw AssertionError() - if (!(element24 !in emptyObjectArray.indices) != range3.contains(element24)) throw AssertionError() -} - -fun testR3xE25() { - // with possible local optimizations - if (3.toShort() in emptyObjectArray.indices != range3.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in emptyObjectArray.indices != !range3.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in emptyObjectArray.indices) != !range3.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in emptyObjectArray.indices) != range3.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in emptyObjectArray.indices != range3.contains(element25)) throw AssertionError() - if (element25 !in emptyObjectArray.indices != !range3.contains(element25)) throw AssertionError() - if (!(element25 in emptyObjectArray.indices) != !range3.contains(element25)) throw AssertionError() - if (!(element25 !in emptyObjectArray.indices) != range3.contains(element25)) throw AssertionError() -} - -fun testR3xE26() { - // with possible local optimizations - if (3 in emptyObjectArray.indices != range3.contains(3)) throw AssertionError() - if (3 !in emptyObjectArray.indices != !range3.contains(3)) throw AssertionError() - if (!(3 in emptyObjectArray.indices) != !range3.contains(3)) throw AssertionError() - if (!(3 !in emptyObjectArray.indices) != range3.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in emptyObjectArray.indices != range3.contains(element26)) throw AssertionError() - if (element26 !in emptyObjectArray.indices != !range3.contains(element26)) throw AssertionError() - if (!(element26 in emptyObjectArray.indices) != !range3.contains(element26)) throw AssertionError() - if (!(element26 !in emptyObjectArray.indices) != range3.contains(element26)) throw AssertionError() -} - -fun testR3xE27() { - // with possible local optimizations - if (3.toLong() in emptyObjectArray.indices != range3.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in emptyObjectArray.indices != !range3.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in emptyObjectArray.indices) != !range3.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in emptyObjectArray.indices) != range3.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in emptyObjectArray.indices != range3.contains(element27)) throw AssertionError() - if (element27 !in emptyObjectArray.indices != !range3.contains(element27)) throw AssertionError() - if (!(element27 in emptyObjectArray.indices) != !range3.contains(element27)) throw AssertionError() - if (!(element27 !in emptyObjectArray.indices) != range3.contains(element27)) throw AssertionError() -} - -fun testR3xE28() { - // with possible local optimizations - if (3.toFloat() in emptyObjectArray.indices != range3.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in emptyObjectArray.indices != !range3.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in emptyObjectArray.indices) != !range3.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in emptyObjectArray.indices) != range3.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in emptyObjectArray.indices != range3.contains(element28)) throw AssertionError() - if (element28 !in emptyObjectArray.indices != !range3.contains(element28)) throw AssertionError() - if (!(element28 in emptyObjectArray.indices) != !range3.contains(element28)) throw AssertionError() - if (!(element28 !in emptyObjectArray.indices) != range3.contains(element28)) throw AssertionError() -} - -fun testR3xE29() { - // with possible local optimizations - if (3.toDouble() in emptyObjectArray.indices != range3.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in emptyObjectArray.indices != !range3.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in emptyObjectArray.indices) != !range3.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in emptyObjectArray.indices) != range3.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in emptyObjectArray.indices != range3.contains(element29)) throw AssertionError() - if (element29 !in emptyObjectArray.indices != !range3.contains(element29)) throw AssertionError() - if (!(element29 in emptyObjectArray.indices) != !range3.contains(element29)) throw AssertionError() - if (!(element29 !in emptyObjectArray.indices) != range3.contains(element29)) throw AssertionError() -} - -fun testR3xE30() { - // with possible local optimizations - if (4.toByte() in emptyObjectArray.indices != range3.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in emptyObjectArray.indices != !range3.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in emptyObjectArray.indices) != !range3.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in emptyObjectArray.indices) != range3.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in emptyObjectArray.indices != range3.contains(element30)) throw AssertionError() - if (element30 !in emptyObjectArray.indices != !range3.contains(element30)) throw AssertionError() - if (!(element30 in emptyObjectArray.indices) != !range3.contains(element30)) throw AssertionError() - if (!(element30 !in emptyObjectArray.indices) != range3.contains(element30)) throw AssertionError() -} - -fun testR3xE31() { - // with possible local optimizations - if (4.toShort() in emptyObjectArray.indices != range3.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in emptyObjectArray.indices != !range3.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in emptyObjectArray.indices) != !range3.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in emptyObjectArray.indices) != range3.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in emptyObjectArray.indices != range3.contains(element31)) throw AssertionError() - if (element31 !in emptyObjectArray.indices != !range3.contains(element31)) throw AssertionError() - if (!(element31 in emptyObjectArray.indices) != !range3.contains(element31)) throw AssertionError() - if (!(element31 !in emptyObjectArray.indices) != range3.contains(element31)) throw AssertionError() -} - -fun testR3xE32() { - // with possible local optimizations - if (4 in emptyObjectArray.indices != range3.contains(4)) throw AssertionError() - if (4 !in emptyObjectArray.indices != !range3.contains(4)) throw AssertionError() - if (!(4 in emptyObjectArray.indices) != !range3.contains(4)) throw AssertionError() - if (!(4 !in emptyObjectArray.indices) != range3.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in emptyObjectArray.indices != range3.contains(element32)) throw AssertionError() - if (element32 !in emptyObjectArray.indices != !range3.contains(element32)) throw AssertionError() - if (!(element32 in emptyObjectArray.indices) != !range3.contains(element32)) throw AssertionError() - if (!(element32 !in emptyObjectArray.indices) != range3.contains(element32)) throw AssertionError() -} - -fun testR3xE33() { - // with possible local optimizations - if (4.toLong() in emptyObjectArray.indices != range3.contains(4.toLong())) throw AssertionError() - if (4.toLong() !in emptyObjectArray.indices != !range3.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() in emptyObjectArray.indices) != !range3.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() !in emptyObjectArray.indices) != range3.contains(4.toLong())) throw AssertionError() - // no local optimizations - if (element33 in emptyObjectArray.indices != range3.contains(element33)) throw AssertionError() - if (element33 !in emptyObjectArray.indices != !range3.contains(element33)) throw AssertionError() - if (!(element33 in emptyObjectArray.indices) != !range3.contains(element33)) throw AssertionError() - if (!(element33 !in emptyObjectArray.indices) != range3.contains(element33)) throw AssertionError() -} - -fun testR3xE34() { - // with possible local optimizations - if (4.toFloat() in emptyObjectArray.indices != range3.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in emptyObjectArray.indices != !range3.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in emptyObjectArray.indices) != !range3.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in emptyObjectArray.indices) != range3.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in emptyObjectArray.indices != range3.contains(element34)) throw AssertionError() - if (element34 !in emptyObjectArray.indices != !range3.contains(element34)) throw AssertionError() - if (!(element34 in emptyObjectArray.indices) != !range3.contains(element34)) throw AssertionError() - if (!(element34 !in emptyObjectArray.indices) != range3.contains(element34)) throw AssertionError() -} - -fun testR3xE35() { - // with possible local optimizations - if (4.toDouble() in emptyObjectArray.indices != range3.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in emptyObjectArray.indices != !range3.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in emptyObjectArray.indices) != !range3.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in emptyObjectArray.indices) != range3.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in emptyObjectArray.indices != range3.contains(element35)) throw AssertionError() - if (element35 !in emptyObjectArray.indices != !range3.contains(element35)) throw AssertionError() - if (!(element35 in emptyObjectArray.indices) != !range3.contains(element35)) throw AssertionError() - if (!(element35 !in emptyObjectArray.indices) != range3.contains(element35)) throw AssertionError() -} - diff --git a/compiler/testData/codegen/box/ranges/contains/generated/charSequenceIndices.kt b/compiler/testData/codegen/box/ranges/contains/generated/charSequenceIndices.kt index 3199d40930e..08c1a424fe3 100644 --- a/compiler/testData/codegen/box/ranges/contains/generated/charSequenceIndices.kt +++ b/compiler/testData/codegen/box/ranges/contains/generated/charSequenceIndices.kt @@ -12,38 +12,26 @@ val element0 = (-1).toByte() val element1 = (-1).toShort() val element2 = (-1) val element3 = (-1).toLong() -val element4 = (-1).toFloat() -val element5 = (-1).toDouble() -val element6 = 0.toByte() -val element7 = 0.toShort() -val element8 = 0 -val element9 = 0.toLong() -val element10 = 0.toFloat() -val element11 = 0.toDouble() -val element12 = 1.toByte() -val element13 = 1.toShort() -val element14 = 1 -val element15 = 1.toLong() -val element16 = 1.toFloat() -val element17 = 1.toDouble() -val element18 = 2.toByte() -val element19 = 2.toShort() -val element20 = 2 -val element21 = 2.toLong() -val element22 = 2.toFloat() -val element23 = 2.toDouble() -val element24 = 3.toByte() -val element25 = 3.toShort() -val element26 = 3 -val element27 = 3.toLong() -val element28 = 3.toFloat() -val element29 = 3.toDouble() -val element30 = 4.toByte() -val element31 = 4.toShort() -val element32 = 4 -val element33 = 4.toLong() -val element34 = 4.toFloat() -val element35 = 4.toDouble() +val element4 = 0.toByte() +val element5 = 0.toShort() +val element6 = 0 +val element7 = 0.toLong() +val element8 = 1.toByte() +val element9 = 1.toShort() +val element10 = 1 +val element11 = 1.toLong() +val element12 = 2.toByte() +val element13 = 2.toShort() +val element14 = 2 +val element15 = 2.toLong() +val element16 = 3.toByte() +val element17 = 3.toShort() +val element18 = 3 +val element19 = 3.toLong() +val element20 = 4.toByte() +val element21 = 4.toShort() +val element22 = 4 +val element23 = 4.toLong() fun box(): String { testR0xE0() @@ -70,18 +58,6 @@ fun box(): String { testR0xE21() testR0xE22() testR0xE23() - testR0xE24() - testR0xE25() - testR0xE26() - testR0xE27() - testR0xE28() - testR0xE29() - testR0xE30() - testR0xE31() - testR0xE32() - testR0xE33() - testR0xE34() - testR0xE35() testR1xE0() testR1xE1() testR1xE2() @@ -106,18 +82,6 @@ fun box(): String { testR1xE21() testR1xE22() testR1xE23() - testR1xE24() - testR1xE25() - testR1xE26() - testR1xE27() - testR1xE28() - testR1xE29() - testR1xE30() - testR1xE31() - testR1xE32() - testR1xE33() - testR1xE34() - testR1xE35() return "OK" } @@ -175,10 +139,10 @@ fun testR0xE3() { fun testR0xE4() { // with possible local optimizations - if ((-1).toFloat() in charSequence.indices != range0.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in charSequence.indices != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in charSequence.indices) != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in charSequence.indices) != range0.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in charSequence.indices != range0.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in charSequence.indices != !range0.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in charSequence.indices) != !range0.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in charSequence.indices) != range0.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in charSequence.indices != range0.contains(element4)) throw AssertionError() if (element4 !in charSequence.indices != !range0.contains(element4)) throw AssertionError() @@ -188,10 +152,10 @@ fun testR0xE4() { fun testR0xE5() { // with possible local optimizations - if ((-1).toDouble() in charSequence.indices != range0.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in charSequence.indices != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in charSequence.indices) != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in charSequence.indices) != range0.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in charSequence.indices != range0.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in charSequence.indices != !range0.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in charSequence.indices) != !range0.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in charSequence.indices) != range0.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in charSequence.indices != range0.contains(element5)) throw AssertionError() if (element5 !in charSequence.indices != !range0.contains(element5)) throw AssertionError() @@ -201,10 +165,10 @@ fun testR0xE5() { fun testR0xE6() { // with possible local optimizations - if (0.toByte() in charSequence.indices != range0.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in charSequence.indices != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in charSequence.indices) != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in charSequence.indices) != range0.contains(0.toByte())) throw AssertionError() + if (0 in charSequence.indices != range0.contains(0)) throw AssertionError() + if (0 !in charSequence.indices != !range0.contains(0)) throw AssertionError() + if (!(0 in charSequence.indices) != !range0.contains(0)) throw AssertionError() + if (!(0 !in charSequence.indices) != range0.contains(0)) throw AssertionError() // no local optimizations if (element6 in charSequence.indices != range0.contains(element6)) throw AssertionError() if (element6 !in charSequence.indices != !range0.contains(element6)) throw AssertionError() @@ -214,10 +178,10 @@ fun testR0xE6() { fun testR0xE7() { // with possible local optimizations - if (0.toShort() in charSequence.indices != range0.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in charSequence.indices != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in charSequence.indices) != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in charSequence.indices) != range0.contains(0.toShort())) throw AssertionError() + if (0.toLong() in charSequence.indices != range0.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in charSequence.indices != !range0.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in charSequence.indices) != !range0.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in charSequence.indices) != range0.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in charSequence.indices != range0.contains(element7)) throw AssertionError() if (element7 !in charSequence.indices != !range0.contains(element7)) throw AssertionError() @@ -227,10 +191,10 @@ fun testR0xE7() { fun testR0xE8() { // with possible local optimizations - if (0 in charSequence.indices != range0.contains(0)) throw AssertionError() - if (0 !in charSequence.indices != !range0.contains(0)) throw AssertionError() - if (!(0 in charSequence.indices) != !range0.contains(0)) throw AssertionError() - if (!(0 !in charSequence.indices) != range0.contains(0)) throw AssertionError() + if (1.toByte() in charSequence.indices != range0.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in charSequence.indices != !range0.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in charSequence.indices) != !range0.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in charSequence.indices) != range0.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in charSequence.indices != range0.contains(element8)) throw AssertionError() if (element8 !in charSequence.indices != !range0.contains(element8)) throw AssertionError() @@ -240,10 +204,10 @@ fun testR0xE8() { fun testR0xE9() { // with possible local optimizations - if (0.toLong() in charSequence.indices != range0.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in charSequence.indices != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in charSequence.indices) != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in charSequence.indices) != range0.contains(0.toLong())) throw AssertionError() + if (1.toShort() in charSequence.indices != range0.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in charSequence.indices != !range0.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in charSequence.indices) != !range0.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in charSequence.indices) != range0.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in charSequence.indices != range0.contains(element9)) throw AssertionError() if (element9 !in charSequence.indices != !range0.contains(element9)) throw AssertionError() @@ -253,10 +217,10 @@ fun testR0xE9() { fun testR0xE10() { // with possible local optimizations - if (0.toFloat() in charSequence.indices != range0.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in charSequence.indices != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in charSequence.indices) != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in charSequence.indices) != range0.contains(0.toFloat())) throw AssertionError() + if (1 in charSequence.indices != range0.contains(1)) throw AssertionError() + if (1 !in charSequence.indices != !range0.contains(1)) throw AssertionError() + if (!(1 in charSequence.indices) != !range0.contains(1)) throw AssertionError() + if (!(1 !in charSequence.indices) != range0.contains(1)) throw AssertionError() // no local optimizations if (element10 in charSequence.indices != range0.contains(element10)) throw AssertionError() if (element10 !in charSequence.indices != !range0.contains(element10)) throw AssertionError() @@ -266,10 +230,10 @@ fun testR0xE10() { fun testR0xE11() { // with possible local optimizations - if (0.toDouble() in charSequence.indices != range0.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in charSequence.indices != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in charSequence.indices) != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in charSequence.indices) != range0.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in charSequence.indices != range0.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in charSequence.indices != !range0.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in charSequence.indices) != !range0.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in charSequence.indices) != range0.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in charSequence.indices != range0.contains(element11)) throw AssertionError() if (element11 !in charSequence.indices != !range0.contains(element11)) throw AssertionError() @@ -279,10 +243,10 @@ fun testR0xE11() { fun testR0xE12() { // with possible local optimizations - if (1.toByte() in charSequence.indices != range0.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in charSequence.indices != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in charSequence.indices) != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in charSequence.indices) != range0.contains(1.toByte())) throw AssertionError() + if (2.toByte() in charSequence.indices != range0.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in charSequence.indices != !range0.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in charSequence.indices) != !range0.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in charSequence.indices) != range0.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in charSequence.indices != range0.contains(element12)) throw AssertionError() if (element12 !in charSequence.indices != !range0.contains(element12)) throw AssertionError() @@ -292,10 +256,10 @@ fun testR0xE12() { fun testR0xE13() { // with possible local optimizations - if (1.toShort() in charSequence.indices != range0.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in charSequence.indices != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in charSequence.indices) != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in charSequence.indices) != range0.contains(1.toShort())) throw AssertionError() + if (2.toShort() in charSequence.indices != range0.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in charSequence.indices != !range0.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in charSequence.indices) != !range0.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in charSequence.indices) != range0.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in charSequence.indices != range0.contains(element13)) throw AssertionError() if (element13 !in charSequence.indices != !range0.contains(element13)) throw AssertionError() @@ -305,10 +269,10 @@ fun testR0xE13() { fun testR0xE14() { // with possible local optimizations - if (1 in charSequence.indices != range0.contains(1)) throw AssertionError() - if (1 !in charSequence.indices != !range0.contains(1)) throw AssertionError() - if (!(1 in charSequence.indices) != !range0.contains(1)) throw AssertionError() - if (!(1 !in charSequence.indices) != range0.contains(1)) throw AssertionError() + if (2 in charSequence.indices != range0.contains(2)) throw AssertionError() + if (2 !in charSequence.indices != !range0.contains(2)) throw AssertionError() + if (!(2 in charSequence.indices) != !range0.contains(2)) throw AssertionError() + if (!(2 !in charSequence.indices) != range0.contains(2)) throw AssertionError() // no local optimizations if (element14 in charSequence.indices != range0.contains(element14)) throw AssertionError() if (element14 !in charSequence.indices != !range0.contains(element14)) throw AssertionError() @@ -318,10 +282,10 @@ fun testR0xE14() { fun testR0xE15() { // with possible local optimizations - if (1.toLong() in charSequence.indices != range0.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in charSequence.indices != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in charSequence.indices) != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in charSequence.indices) != range0.contains(1.toLong())) throw AssertionError() + if (2.toLong() in charSequence.indices != range0.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in charSequence.indices != !range0.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in charSequence.indices) != !range0.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in charSequence.indices) != range0.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in charSequence.indices != range0.contains(element15)) throw AssertionError() if (element15 !in charSequence.indices != !range0.contains(element15)) throw AssertionError() @@ -331,10 +295,10 @@ fun testR0xE15() { fun testR0xE16() { // with possible local optimizations - if (1.toFloat() in charSequence.indices != range0.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in charSequence.indices != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in charSequence.indices) != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in charSequence.indices) != range0.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in charSequence.indices != range0.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in charSequence.indices != !range0.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in charSequence.indices) != !range0.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in charSequence.indices) != range0.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in charSequence.indices != range0.contains(element16)) throw AssertionError() if (element16 !in charSequence.indices != !range0.contains(element16)) throw AssertionError() @@ -344,10 +308,10 @@ fun testR0xE16() { fun testR0xE17() { // with possible local optimizations - if (1.toDouble() in charSequence.indices != range0.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in charSequence.indices != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in charSequence.indices) != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in charSequence.indices) != range0.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in charSequence.indices != range0.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in charSequence.indices != !range0.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in charSequence.indices) != !range0.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in charSequence.indices) != range0.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in charSequence.indices != range0.contains(element17)) throw AssertionError() if (element17 !in charSequence.indices != !range0.contains(element17)) throw AssertionError() @@ -357,10 +321,10 @@ fun testR0xE17() { fun testR0xE18() { // with possible local optimizations - if (2.toByte() in charSequence.indices != range0.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in charSequence.indices != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in charSequence.indices) != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in charSequence.indices) != range0.contains(2.toByte())) throw AssertionError() + if (3 in charSequence.indices != range0.contains(3)) throw AssertionError() + if (3 !in charSequence.indices != !range0.contains(3)) throw AssertionError() + if (!(3 in charSequence.indices) != !range0.contains(3)) throw AssertionError() + if (!(3 !in charSequence.indices) != range0.contains(3)) throw AssertionError() // no local optimizations if (element18 in charSequence.indices != range0.contains(element18)) throw AssertionError() if (element18 !in charSequence.indices != !range0.contains(element18)) throw AssertionError() @@ -370,10 +334,10 @@ fun testR0xE18() { fun testR0xE19() { // with possible local optimizations - if (2.toShort() in charSequence.indices != range0.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in charSequence.indices != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in charSequence.indices) != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in charSequence.indices) != range0.contains(2.toShort())) throw AssertionError() + if (3.toLong() in charSequence.indices != range0.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in charSequence.indices != !range0.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in charSequence.indices) != !range0.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in charSequence.indices) != range0.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in charSequence.indices != range0.contains(element19)) throw AssertionError() if (element19 !in charSequence.indices != !range0.contains(element19)) throw AssertionError() @@ -383,10 +347,10 @@ fun testR0xE19() { fun testR0xE20() { // with possible local optimizations - if (2 in charSequence.indices != range0.contains(2)) throw AssertionError() - if (2 !in charSequence.indices != !range0.contains(2)) throw AssertionError() - if (!(2 in charSequence.indices) != !range0.contains(2)) throw AssertionError() - if (!(2 !in charSequence.indices) != range0.contains(2)) throw AssertionError() + if (4.toByte() in charSequence.indices != range0.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in charSequence.indices != !range0.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in charSequence.indices) != !range0.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in charSequence.indices) != range0.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in charSequence.indices != range0.contains(element20)) throw AssertionError() if (element20 !in charSequence.indices != !range0.contains(element20)) throw AssertionError() @@ -396,10 +360,10 @@ fun testR0xE20() { fun testR0xE21() { // with possible local optimizations - if (2.toLong() in charSequence.indices != range0.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in charSequence.indices != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in charSequence.indices) != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in charSequence.indices) != range0.contains(2.toLong())) throw AssertionError() + if (4.toShort() in charSequence.indices != range0.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in charSequence.indices != !range0.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in charSequence.indices) != !range0.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in charSequence.indices) != range0.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in charSequence.indices != range0.contains(element21)) throw AssertionError() if (element21 !in charSequence.indices != !range0.contains(element21)) throw AssertionError() @@ -409,10 +373,10 @@ fun testR0xE21() { fun testR0xE22() { // with possible local optimizations - if (2.toFloat() in charSequence.indices != range0.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in charSequence.indices != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in charSequence.indices) != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in charSequence.indices) != range0.contains(2.toFloat())) throw AssertionError() + if (4 in charSequence.indices != range0.contains(4)) throw AssertionError() + if (4 !in charSequence.indices != !range0.contains(4)) throw AssertionError() + if (!(4 in charSequence.indices) != !range0.contains(4)) throw AssertionError() + if (!(4 !in charSequence.indices) != range0.contains(4)) throw AssertionError() // no local optimizations if (element22 in charSequence.indices != range0.contains(element22)) throw AssertionError() if (element22 !in charSequence.indices != !range0.contains(element22)) throw AssertionError() @@ -421,172 +385,16 @@ fun testR0xE22() { } fun testR0xE23() { - // with possible local optimizations - if (2.toDouble() in charSequence.indices != range0.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in charSequence.indices != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in charSequence.indices) != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in charSequence.indices) != range0.contains(2.toDouble())) throw AssertionError() - // no local optimizations - if (element23 in charSequence.indices != range0.contains(element23)) throw AssertionError() - if (element23 !in charSequence.indices != !range0.contains(element23)) throw AssertionError() - if (!(element23 in charSequence.indices) != !range0.contains(element23)) throw AssertionError() - if (!(element23 !in charSequence.indices) != range0.contains(element23)) throw AssertionError() -} - -fun testR0xE24() { - // with possible local optimizations - if (3.toByte() in charSequence.indices != range0.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in charSequence.indices != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in charSequence.indices) != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in charSequence.indices) != range0.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in charSequence.indices != range0.contains(element24)) throw AssertionError() - if (element24 !in charSequence.indices != !range0.contains(element24)) throw AssertionError() - if (!(element24 in charSequence.indices) != !range0.contains(element24)) throw AssertionError() - if (!(element24 !in charSequence.indices) != range0.contains(element24)) throw AssertionError() -} - -fun testR0xE25() { - // with possible local optimizations - if (3.toShort() in charSequence.indices != range0.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in charSequence.indices != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in charSequence.indices) != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in charSequence.indices) != range0.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in charSequence.indices != range0.contains(element25)) throw AssertionError() - if (element25 !in charSequence.indices != !range0.contains(element25)) throw AssertionError() - if (!(element25 in charSequence.indices) != !range0.contains(element25)) throw AssertionError() - if (!(element25 !in charSequence.indices) != range0.contains(element25)) throw AssertionError() -} - -fun testR0xE26() { - // with possible local optimizations - if (3 in charSequence.indices != range0.contains(3)) throw AssertionError() - if (3 !in charSequence.indices != !range0.contains(3)) throw AssertionError() - if (!(3 in charSequence.indices) != !range0.contains(3)) throw AssertionError() - if (!(3 !in charSequence.indices) != range0.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in charSequence.indices != range0.contains(element26)) throw AssertionError() - if (element26 !in charSequence.indices != !range0.contains(element26)) throw AssertionError() - if (!(element26 in charSequence.indices) != !range0.contains(element26)) throw AssertionError() - if (!(element26 !in charSequence.indices) != range0.contains(element26)) throw AssertionError() -} - -fun testR0xE27() { - // with possible local optimizations - if (3.toLong() in charSequence.indices != range0.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in charSequence.indices != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in charSequence.indices) != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in charSequence.indices) != range0.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in charSequence.indices != range0.contains(element27)) throw AssertionError() - if (element27 !in charSequence.indices != !range0.contains(element27)) throw AssertionError() - if (!(element27 in charSequence.indices) != !range0.contains(element27)) throw AssertionError() - if (!(element27 !in charSequence.indices) != range0.contains(element27)) throw AssertionError() -} - -fun testR0xE28() { - // with possible local optimizations - if (3.toFloat() in charSequence.indices != range0.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in charSequence.indices != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in charSequence.indices) != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in charSequence.indices) != range0.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in charSequence.indices != range0.contains(element28)) throw AssertionError() - if (element28 !in charSequence.indices != !range0.contains(element28)) throw AssertionError() - if (!(element28 in charSequence.indices) != !range0.contains(element28)) throw AssertionError() - if (!(element28 !in charSequence.indices) != range0.contains(element28)) throw AssertionError() -} - -fun testR0xE29() { - // with possible local optimizations - if (3.toDouble() in charSequence.indices != range0.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in charSequence.indices != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in charSequence.indices) != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in charSequence.indices) != range0.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in charSequence.indices != range0.contains(element29)) throw AssertionError() - if (element29 !in charSequence.indices != !range0.contains(element29)) throw AssertionError() - if (!(element29 in charSequence.indices) != !range0.contains(element29)) throw AssertionError() - if (!(element29 !in charSequence.indices) != range0.contains(element29)) throw AssertionError() -} - -fun testR0xE30() { - // with possible local optimizations - if (4.toByte() in charSequence.indices != range0.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in charSequence.indices != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in charSequence.indices) != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in charSequence.indices) != range0.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in charSequence.indices != range0.contains(element30)) throw AssertionError() - if (element30 !in charSequence.indices != !range0.contains(element30)) throw AssertionError() - if (!(element30 in charSequence.indices) != !range0.contains(element30)) throw AssertionError() - if (!(element30 !in charSequence.indices) != range0.contains(element30)) throw AssertionError() -} - -fun testR0xE31() { - // with possible local optimizations - if (4.toShort() in charSequence.indices != range0.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in charSequence.indices != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in charSequence.indices) != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in charSequence.indices) != range0.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in charSequence.indices != range0.contains(element31)) throw AssertionError() - if (element31 !in charSequence.indices != !range0.contains(element31)) throw AssertionError() - if (!(element31 in charSequence.indices) != !range0.contains(element31)) throw AssertionError() - if (!(element31 !in charSequence.indices) != range0.contains(element31)) throw AssertionError() -} - -fun testR0xE32() { - // with possible local optimizations - if (4 in charSequence.indices != range0.contains(4)) throw AssertionError() - if (4 !in charSequence.indices != !range0.contains(4)) throw AssertionError() - if (!(4 in charSequence.indices) != !range0.contains(4)) throw AssertionError() - if (!(4 !in charSequence.indices) != range0.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in charSequence.indices != range0.contains(element32)) throw AssertionError() - if (element32 !in charSequence.indices != !range0.contains(element32)) throw AssertionError() - if (!(element32 in charSequence.indices) != !range0.contains(element32)) throw AssertionError() - if (!(element32 !in charSequence.indices) != range0.contains(element32)) throw AssertionError() -} - -fun testR0xE33() { // with possible local optimizations if (4.toLong() in charSequence.indices != range0.contains(4.toLong())) throw AssertionError() if (4.toLong() !in charSequence.indices != !range0.contains(4.toLong())) throw AssertionError() if (!(4.toLong() in charSequence.indices) != !range0.contains(4.toLong())) throw AssertionError() if (!(4.toLong() !in charSequence.indices) != range0.contains(4.toLong())) throw AssertionError() // no local optimizations - if (element33 in charSequence.indices != range0.contains(element33)) throw AssertionError() - if (element33 !in charSequence.indices != !range0.contains(element33)) throw AssertionError() - if (!(element33 in charSequence.indices) != !range0.contains(element33)) throw AssertionError() - if (!(element33 !in charSequence.indices) != range0.contains(element33)) throw AssertionError() -} - -fun testR0xE34() { - // with possible local optimizations - if (4.toFloat() in charSequence.indices != range0.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in charSequence.indices != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in charSequence.indices) != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in charSequence.indices) != range0.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in charSequence.indices != range0.contains(element34)) throw AssertionError() - if (element34 !in charSequence.indices != !range0.contains(element34)) throw AssertionError() - if (!(element34 in charSequence.indices) != !range0.contains(element34)) throw AssertionError() - if (!(element34 !in charSequence.indices) != range0.contains(element34)) throw AssertionError() -} - -fun testR0xE35() { - // with possible local optimizations - if (4.toDouble() in charSequence.indices != range0.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in charSequence.indices != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in charSequence.indices) != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in charSequence.indices) != range0.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in charSequence.indices != range0.contains(element35)) throw AssertionError() - if (element35 !in charSequence.indices != !range0.contains(element35)) throw AssertionError() - if (!(element35 in charSequence.indices) != !range0.contains(element35)) throw AssertionError() - if (!(element35 !in charSequence.indices) != range0.contains(element35)) throw AssertionError() + if (element23 in charSequence.indices != range0.contains(element23)) throw AssertionError() + if (element23 !in charSequence.indices != !range0.contains(element23)) throw AssertionError() + if (!(element23 in charSequence.indices) != !range0.contains(element23)) throw AssertionError() + if (!(element23 !in charSequence.indices) != range0.contains(element23)) throw AssertionError() } fun testR1xE0() { @@ -643,10 +451,10 @@ fun testR1xE3() { fun testR1xE4() { // with possible local optimizations - if ((-1).toFloat() in emptyCharSequence.indices != range1.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in emptyCharSequence.indices != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in emptyCharSequence.indices) != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in emptyCharSequence.indices) != range1.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in emptyCharSequence.indices != range1.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in emptyCharSequence.indices != !range1.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in emptyCharSequence.indices) != !range1.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in emptyCharSequence.indices) != range1.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in emptyCharSequence.indices != range1.contains(element4)) throw AssertionError() if (element4 !in emptyCharSequence.indices != !range1.contains(element4)) throw AssertionError() @@ -656,10 +464,10 @@ fun testR1xE4() { fun testR1xE5() { // with possible local optimizations - if ((-1).toDouble() in emptyCharSequence.indices != range1.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in emptyCharSequence.indices != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in emptyCharSequence.indices) != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in emptyCharSequence.indices) != range1.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in emptyCharSequence.indices != range1.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in emptyCharSequence.indices != !range1.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in emptyCharSequence.indices) != !range1.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in emptyCharSequence.indices) != range1.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in emptyCharSequence.indices != range1.contains(element5)) throw AssertionError() if (element5 !in emptyCharSequence.indices != !range1.contains(element5)) throw AssertionError() @@ -669,10 +477,10 @@ fun testR1xE5() { fun testR1xE6() { // with possible local optimizations - if (0.toByte() in emptyCharSequence.indices != range1.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in emptyCharSequence.indices != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in emptyCharSequence.indices) != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in emptyCharSequence.indices) != range1.contains(0.toByte())) throw AssertionError() + if (0 in emptyCharSequence.indices != range1.contains(0)) throw AssertionError() + if (0 !in emptyCharSequence.indices != !range1.contains(0)) throw AssertionError() + if (!(0 in emptyCharSequence.indices) != !range1.contains(0)) throw AssertionError() + if (!(0 !in emptyCharSequence.indices) != range1.contains(0)) throw AssertionError() // no local optimizations if (element6 in emptyCharSequence.indices != range1.contains(element6)) throw AssertionError() if (element6 !in emptyCharSequence.indices != !range1.contains(element6)) throw AssertionError() @@ -682,10 +490,10 @@ fun testR1xE6() { fun testR1xE7() { // with possible local optimizations - if (0.toShort() in emptyCharSequence.indices != range1.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in emptyCharSequence.indices != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in emptyCharSequence.indices) != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in emptyCharSequence.indices) != range1.contains(0.toShort())) throw AssertionError() + if (0.toLong() in emptyCharSequence.indices != range1.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in emptyCharSequence.indices != !range1.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in emptyCharSequence.indices) != !range1.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in emptyCharSequence.indices) != range1.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in emptyCharSequence.indices != range1.contains(element7)) throw AssertionError() if (element7 !in emptyCharSequence.indices != !range1.contains(element7)) throw AssertionError() @@ -695,10 +503,10 @@ fun testR1xE7() { fun testR1xE8() { // with possible local optimizations - if (0 in emptyCharSequence.indices != range1.contains(0)) throw AssertionError() - if (0 !in emptyCharSequence.indices != !range1.contains(0)) throw AssertionError() - if (!(0 in emptyCharSequence.indices) != !range1.contains(0)) throw AssertionError() - if (!(0 !in emptyCharSequence.indices) != range1.contains(0)) throw AssertionError() + if (1.toByte() in emptyCharSequence.indices != range1.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in emptyCharSequence.indices != !range1.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in emptyCharSequence.indices) != !range1.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in emptyCharSequence.indices) != range1.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in emptyCharSequence.indices != range1.contains(element8)) throw AssertionError() if (element8 !in emptyCharSequence.indices != !range1.contains(element8)) throw AssertionError() @@ -708,10 +516,10 @@ fun testR1xE8() { fun testR1xE9() { // with possible local optimizations - if (0.toLong() in emptyCharSequence.indices != range1.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in emptyCharSequence.indices != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in emptyCharSequence.indices) != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in emptyCharSequence.indices) != range1.contains(0.toLong())) throw AssertionError() + if (1.toShort() in emptyCharSequence.indices != range1.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in emptyCharSequence.indices != !range1.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in emptyCharSequence.indices) != !range1.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in emptyCharSequence.indices) != range1.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in emptyCharSequence.indices != range1.contains(element9)) throw AssertionError() if (element9 !in emptyCharSequence.indices != !range1.contains(element9)) throw AssertionError() @@ -721,10 +529,10 @@ fun testR1xE9() { fun testR1xE10() { // with possible local optimizations - if (0.toFloat() in emptyCharSequence.indices != range1.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in emptyCharSequence.indices != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in emptyCharSequence.indices) != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in emptyCharSequence.indices) != range1.contains(0.toFloat())) throw AssertionError() + if (1 in emptyCharSequence.indices != range1.contains(1)) throw AssertionError() + if (1 !in emptyCharSequence.indices != !range1.contains(1)) throw AssertionError() + if (!(1 in emptyCharSequence.indices) != !range1.contains(1)) throw AssertionError() + if (!(1 !in emptyCharSequence.indices) != range1.contains(1)) throw AssertionError() // no local optimizations if (element10 in emptyCharSequence.indices != range1.contains(element10)) throw AssertionError() if (element10 !in emptyCharSequence.indices != !range1.contains(element10)) throw AssertionError() @@ -734,10 +542,10 @@ fun testR1xE10() { fun testR1xE11() { // with possible local optimizations - if (0.toDouble() in emptyCharSequence.indices != range1.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in emptyCharSequence.indices != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in emptyCharSequence.indices) != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in emptyCharSequence.indices) != range1.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in emptyCharSequence.indices != range1.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in emptyCharSequence.indices != !range1.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in emptyCharSequence.indices) != !range1.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in emptyCharSequence.indices) != range1.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in emptyCharSequence.indices != range1.contains(element11)) throw AssertionError() if (element11 !in emptyCharSequence.indices != !range1.contains(element11)) throw AssertionError() @@ -747,10 +555,10 @@ fun testR1xE11() { fun testR1xE12() { // with possible local optimizations - if (1.toByte() in emptyCharSequence.indices != range1.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in emptyCharSequence.indices != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in emptyCharSequence.indices) != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in emptyCharSequence.indices) != range1.contains(1.toByte())) throw AssertionError() + if (2.toByte() in emptyCharSequence.indices != range1.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in emptyCharSequence.indices != !range1.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in emptyCharSequence.indices) != !range1.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in emptyCharSequence.indices) != range1.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in emptyCharSequence.indices != range1.contains(element12)) throw AssertionError() if (element12 !in emptyCharSequence.indices != !range1.contains(element12)) throw AssertionError() @@ -760,10 +568,10 @@ fun testR1xE12() { fun testR1xE13() { // with possible local optimizations - if (1.toShort() in emptyCharSequence.indices != range1.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in emptyCharSequence.indices != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in emptyCharSequence.indices) != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in emptyCharSequence.indices) != range1.contains(1.toShort())) throw AssertionError() + if (2.toShort() in emptyCharSequence.indices != range1.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in emptyCharSequence.indices != !range1.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in emptyCharSequence.indices) != !range1.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in emptyCharSequence.indices) != range1.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in emptyCharSequence.indices != range1.contains(element13)) throw AssertionError() if (element13 !in emptyCharSequence.indices != !range1.contains(element13)) throw AssertionError() @@ -773,10 +581,10 @@ fun testR1xE13() { fun testR1xE14() { // with possible local optimizations - if (1 in emptyCharSequence.indices != range1.contains(1)) throw AssertionError() - if (1 !in emptyCharSequence.indices != !range1.contains(1)) throw AssertionError() - if (!(1 in emptyCharSequence.indices) != !range1.contains(1)) throw AssertionError() - if (!(1 !in emptyCharSequence.indices) != range1.contains(1)) throw AssertionError() + if (2 in emptyCharSequence.indices != range1.contains(2)) throw AssertionError() + if (2 !in emptyCharSequence.indices != !range1.contains(2)) throw AssertionError() + if (!(2 in emptyCharSequence.indices) != !range1.contains(2)) throw AssertionError() + if (!(2 !in emptyCharSequence.indices) != range1.contains(2)) throw AssertionError() // no local optimizations if (element14 in emptyCharSequence.indices != range1.contains(element14)) throw AssertionError() if (element14 !in emptyCharSequence.indices != !range1.contains(element14)) throw AssertionError() @@ -786,10 +594,10 @@ fun testR1xE14() { fun testR1xE15() { // with possible local optimizations - if (1.toLong() in emptyCharSequence.indices != range1.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in emptyCharSequence.indices != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in emptyCharSequence.indices) != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in emptyCharSequence.indices) != range1.contains(1.toLong())) throw AssertionError() + if (2.toLong() in emptyCharSequence.indices != range1.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in emptyCharSequence.indices != !range1.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in emptyCharSequence.indices) != !range1.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in emptyCharSequence.indices) != range1.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in emptyCharSequence.indices != range1.contains(element15)) throw AssertionError() if (element15 !in emptyCharSequence.indices != !range1.contains(element15)) throw AssertionError() @@ -799,10 +607,10 @@ fun testR1xE15() { fun testR1xE16() { // with possible local optimizations - if (1.toFloat() in emptyCharSequence.indices != range1.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in emptyCharSequence.indices != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in emptyCharSequence.indices) != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in emptyCharSequence.indices) != range1.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in emptyCharSequence.indices != range1.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in emptyCharSequence.indices != !range1.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in emptyCharSequence.indices) != !range1.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in emptyCharSequence.indices) != range1.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in emptyCharSequence.indices != range1.contains(element16)) throw AssertionError() if (element16 !in emptyCharSequence.indices != !range1.contains(element16)) throw AssertionError() @@ -812,10 +620,10 @@ fun testR1xE16() { fun testR1xE17() { // with possible local optimizations - if (1.toDouble() in emptyCharSequence.indices != range1.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in emptyCharSequence.indices != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in emptyCharSequence.indices) != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in emptyCharSequence.indices) != range1.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in emptyCharSequence.indices != range1.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in emptyCharSequence.indices != !range1.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in emptyCharSequence.indices) != !range1.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in emptyCharSequence.indices) != range1.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in emptyCharSequence.indices != range1.contains(element17)) throw AssertionError() if (element17 !in emptyCharSequence.indices != !range1.contains(element17)) throw AssertionError() @@ -825,10 +633,10 @@ fun testR1xE17() { fun testR1xE18() { // with possible local optimizations - if (2.toByte() in emptyCharSequence.indices != range1.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in emptyCharSequence.indices != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in emptyCharSequence.indices) != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in emptyCharSequence.indices) != range1.contains(2.toByte())) throw AssertionError() + if (3 in emptyCharSequence.indices != range1.contains(3)) throw AssertionError() + if (3 !in emptyCharSequence.indices != !range1.contains(3)) throw AssertionError() + if (!(3 in emptyCharSequence.indices) != !range1.contains(3)) throw AssertionError() + if (!(3 !in emptyCharSequence.indices) != range1.contains(3)) throw AssertionError() // no local optimizations if (element18 in emptyCharSequence.indices != range1.contains(element18)) throw AssertionError() if (element18 !in emptyCharSequence.indices != !range1.contains(element18)) throw AssertionError() @@ -838,10 +646,10 @@ fun testR1xE18() { fun testR1xE19() { // with possible local optimizations - if (2.toShort() in emptyCharSequence.indices != range1.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in emptyCharSequence.indices != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in emptyCharSequence.indices) != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in emptyCharSequence.indices) != range1.contains(2.toShort())) throw AssertionError() + if (3.toLong() in emptyCharSequence.indices != range1.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in emptyCharSequence.indices != !range1.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in emptyCharSequence.indices) != !range1.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in emptyCharSequence.indices) != range1.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in emptyCharSequence.indices != range1.contains(element19)) throw AssertionError() if (element19 !in emptyCharSequence.indices != !range1.contains(element19)) throw AssertionError() @@ -851,10 +659,10 @@ fun testR1xE19() { fun testR1xE20() { // with possible local optimizations - if (2 in emptyCharSequence.indices != range1.contains(2)) throw AssertionError() - if (2 !in emptyCharSequence.indices != !range1.contains(2)) throw AssertionError() - if (!(2 in emptyCharSequence.indices) != !range1.contains(2)) throw AssertionError() - if (!(2 !in emptyCharSequence.indices) != range1.contains(2)) throw AssertionError() + if (4.toByte() in emptyCharSequence.indices != range1.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in emptyCharSequence.indices != !range1.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in emptyCharSequence.indices) != !range1.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in emptyCharSequence.indices) != range1.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in emptyCharSequence.indices != range1.contains(element20)) throw AssertionError() if (element20 !in emptyCharSequence.indices != !range1.contains(element20)) throw AssertionError() @@ -864,10 +672,10 @@ fun testR1xE20() { fun testR1xE21() { // with possible local optimizations - if (2.toLong() in emptyCharSequence.indices != range1.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in emptyCharSequence.indices != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in emptyCharSequence.indices) != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in emptyCharSequence.indices) != range1.contains(2.toLong())) throw AssertionError() + if (4.toShort() in emptyCharSequence.indices != range1.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in emptyCharSequence.indices != !range1.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in emptyCharSequence.indices) != !range1.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in emptyCharSequence.indices) != range1.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in emptyCharSequence.indices != range1.contains(element21)) throw AssertionError() if (element21 !in emptyCharSequence.indices != !range1.contains(element21)) throw AssertionError() @@ -877,10 +685,10 @@ fun testR1xE21() { fun testR1xE22() { // with possible local optimizations - if (2.toFloat() in emptyCharSequence.indices != range1.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in emptyCharSequence.indices != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in emptyCharSequence.indices) != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in emptyCharSequence.indices) != range1.contains(2.toFloat())) throw AssertionError() + if (4 in emptyCharSequence.indices != range1.contains(4)) throw AssertionError() + if (4 !in emptyCharSequence.indices != !range1.contains(4)) throw AssertionError() + if (!(4 in emptyCharSequence.indices) != !range1.contains(4)) throw AssertionError() + if (!(4 !in emptyCharSequence.indices) != range1.contains(4)) throw AssertionError() // no local optimizations if (element22 in emptyCharSequence.indices != range1.contains(element22)) throw AssertionError() if (element22 !in emptyCharSequence.indices != !range1.contains(element22)) throw AssertionError() @@ -890,10 +698,10 @@ fun testR1xE22() { fun testR1xE23() { // with possible local optimizations - if (2.toDouble() in emptyCharSequence.indices != range1.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in emptyCharSequence.indices != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in emptyCharSequence.indices) != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in emptyCharSequence.indices) != range1.contains(2.toDouble())) throw AssertionError() + if (4.toLong() in emptyCharSequence.indices != range1.contains(4.toLong())) throw AssertionError() + if (4.toLong() !in emptyCharSequence.indices != !range1.contains(4.toLong())) throw AssertionError() + if (!(4.toLong() in emptyCharSequence.indices) != !range1.contains(4.toLong())) throw AssertionError() + if (!(4.toLong() !in emptyCharSequence.indices) != range1.contains(4.toLong())) throw AssertionError() // no local optimizations if (element23 in emptyCharSequence.indices != range1.contains(element23)) throw AssertionError() if (element23 !in emptyCharSequence.indices != !range1.contains(element23)) throw AssertionError() @@ -901,160 +709,4 @@ fun testR1xE23() { if (!(element23 !in emptyCharSequence.indices) != range1.contains(element23)) throw AssertionError() } -fun testR1xE24() { - // with possible local optimizations - if (3.toByte() in emptyCharSequence.indices != range1.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in emptyCharSequence.indices != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in emptyCharSequence.indices) != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in emptyCharSequence.indices) != range1.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in emptyCharSequence.indices != range1.contains(element24)) throw AssertionError() - if (element24 !in emptyCharSequence.indices != !range1.contains(element24)) throw AssertionError() - if (!(element24 in emptyCharSequence.indices) != !range1.contains(element24)) throw AssertionError() - if (!(element24 !in emptyCharSequence.indices) != range1.contains(element24)) throw AssertionError() -} - -fun testR1xE25() { - // with possible local optimizations - if (3.toShort() in emptyCharSequence.indices != range1.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in emptyCharSequence.indices != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in emptyCharSequence.indices) != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in emptyCharSequence.indices) != range1.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in emptyCharSequence.indices != range1.contains(element25)) throw AssertionError() - if (element25 !in emptyCharSequence.indices != !range1.contains(element25)) throw AssertionError() - if (!(element25 in emptyCharSequence.indices) != !range1.contains(element25)) throw AssertionError() - if (!(element25 !in emptyCharSequence.indices) != range1.contains(element25)) throw AssertionError() -} - -fun testR1xE26() { - // with possible local optimizations - if (3 in emptyCharSequence.indices != range1.contains(3)) throw AssertionError() - if (3 !in emptyCharSequence.indices != !range1.contains(3)) throw AssertionError() - if (!(3 in emptyCharSequence.indices) != !range1.contains(3)) throw AssertionError() - if (!(3 !in emptyCharSequence.indices) != range1.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in emptyCharSequence.indices != range1.contains(element26)) throw AssertionError() - if (element26 !in emptyCharSequence.indices != !range1.contains(element26)) throw AssertionError() - if (!(element26 in emptyCharSequence.indices) != !range1.contains(element26)) throw AssertionError() - if (!(element26 !in emptyCharSequence.indices) != range1.contains(element26)) throw AssertionError() -} - -fun testR1xE27() { - // with possible local optimizations - if (3.toLong() in emptyCharSequence.indices != range1.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in emptyCharSequence.indices != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in emptyCharSequence.indices) != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in emptyCharSequence.indices) != range1.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in emptyCharSequence.indices != range1.contains(element27)) throw AssertionError() - if (element27 !in emptyCharSequence.indices != !range1.contains(element27)) throw AssertionError() - if (!(element27 in emptyCharSequence.indices) != !range1.contains(element27)) throw AssertionError() - if (!(element27 !in emptyCharSequence.indices) != range1.contains(element27)) throw AssertionError() -} - -fun testR1xE28() { - // with possible local optimizations - if (3.toFloat() in emptyCharSequence.indices != range1.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in emptyCharSequence.indices != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in emptyCharSequence.indices) != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in emptyCharSequence.indices) != range1.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in emptyCharSequence.indices != range1.contains(element28)) throw AssertionError() - if (element28 !in emptyCharSequence.indices != !range1.contains(element28)) throw AssertionError() - if (!(element28 in emptyCharSequence.indices) != !range1.contains(element28)) throw AssertionError() - if (!(element28 !in emptyCharSequence.indices) != range1.contains(element28)) throw AssertionError() -} - -fun testR1xE29() { - // with possible local optimizations - if (3.toDouble() in emptyCharSequence.indices != range1.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in emptyCharSequence.indices != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in emptyCharSequence.indices) != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in emptyCharSequence.indices) != range1.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in emptyCharSequence.indices != range1.contains(element29)) throw AssertionError() - if (element29 !in emptyCharSequence.indices != !range1.contains(element29)) throw AssertionError() - if (!(element29 in emptyCharSequence.indices) != !range1.contains(element29)) throw AssertionError() - if (!(element29 !in emptyCharSequence.indices) != range1.contains(element29)) throw AssertionError() -} - -fun testR1xE30() { - // with possible local optimizations - if (4.toByte() in emptyCharSequence.indices != range1.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in emptyCharSequence.indices != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in emptyCharSequence.indices) != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in emptyCharSequence.indices) != range1.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in emptyCharSequence.indices != range1.contains(element30)) throw AssertionError() - if (element30 !in emptyCharSequence.indices != !range1.contains(element30)) throw AssertionError() - if (!(element30 in emptyCharSequence.indices) != !range1.contains(element30)) throw AssertionError() - if (!(element30 !in emptyCharSequence.indices) != range1.contains(element30)) throw AssertionError() -} - -fun testR1xE31() { - // with possible local optimizations - if (4.toShort() in emptyCharSequence.indices != range1.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in emptyCharSequence.indices != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in emptyCharSequence.indices) != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in emptyCharSequence.indices) != range1.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in emptyCharSequence.indices != range1.contains(element31)) throw AssertionError() - if (element31 !in emptyCharSequence.indices != !range1.contains(element31)) throw AssertionError() - if (!(element31 in emptyCharSequence.indices) != !range1.contains(element31)) throw AssertionError() - if (!(element31 !in emptyCharSequence.indices) != range1.contains(element31)) throw AssertionError() -} - -fun testR1xE32() { - // with possible local optimizations - if (4 in emptyCharSequence.indices != range1.contains(4)) throw AssertionError() - if (4 !in emptyCharSequence.indices != !range1.contains(4)) throw AssertionError() - if (!(4 in emptyCharSequence.indices) != !range1.contains(4)) throw AssertionError() - if (!(4 !in emptyCharSequence.indices) != range1.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in emptyCharSequence.indices != range1.contains(element32)) throw AssertionError() - if (element32 !in emptyCharSequence.indices != !range1.contains(element32)) throw AssertionError() - if (!(element32 in emptyCharSequence.indices) != !range1.contains(element32)) throw AssertionError() - if (!(element32 !in emptyCharSequence.indices) != range1.contains(element32)) throw AssertionError() -} - -fun testR1xE33() { - // with possible local optimizations - if (4.toLong() in emptyCharSequence.indices != range1.contains(4.toLong())) throw AssertionError() - if (4.toLong() !in emptyCharSequence.indices != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() in emptyCharSequence.indices) != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() !in emptyCharSequence.indices) != range1.contains(4.toLong())) throw AssertionError() - // no local optimizations - if (element33 in emptyCharSequence.indices != range1.contains(element33)) throw AssertionError() - if (element33 !in emptyCharSequence.indices != !range1.contains(element33)) throw AssertionError() - if (!(element33 in emptyCharSequence.indices) != !range1.contains(element33)) throw AssertionError() - if (!(element33 !in emptyCharSequence.indices) != range1.contains(element33)) throw AssertionError() -} - -fun testR1xE34() { - // with possible local optimizations - if (4.toFloat() in emptyCharSequence.indices != range1.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in emptyCharSequence.indices != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in emptyCharSequence.indices) != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in emptyCharSequence.indices) != range1.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in emptyCharSequence.indices != range1.contains(element34)) throw AssertionError() - if (element34 !in emptyCharSequence.indices != !range1.contains(element34)) throw AssertionError() - if (!(element34 in emptyCharSequence.indices) != !range1.contains(element34)) throw AssertionError() - if (!(element34 !in emptyCharSequence.indices) != range1.contains(element34)) throw AssertionError() -} - -fun testR1xE35() { - // with possible local optimizations - if (4.toDouble() in emptyCharSequence.indices != range1.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in emptyCharSequence.indices != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in emptyCharSequence.indices) != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in emptyCharSequence.indices) != range1.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in emptyCharSequence.indices != range1.contains(element35)) throw AssertionError() - if (element35 !in emptyCharSequence.indices != !range1.contains(element35)) throw AssertionError() - if (!(element35 in emptyCharSequence.indices) != !range1.contains(element35)) throw AssertionError() - if (!(element35 !in emptyCharSequence.indices) != range1.contains(element35)) throw AssertionError() -} - diff --git a/compiler/testData/codegen/box/ranges/contains/generated/collectionIndices.kt b/compiler/testData/codegen/box/ranges/contains/generated/collectionIndices.kt index 8da68230056..e4b9c134e2e 100644 --- a/compiler/testData/codegen/box/ranges/contains/generated/collectionIndices.kt +++ b/compiler/testData/codegen/box/ranges/contains/generated/collectionIndices.kt @@ -12,38 +12,26 @@ val element0 = (-1).toByte() val element1 = (-1).toShort() val element2 = (-1) val element3 = (-1).toLong() -val element4 = (-1).toFloat() -val element5 = (-1).toDouble() -val element6 = 0.toByte() -val element7 = 0.toShort() -val element8 = 0 -val element9 = 0.toLong() -val element10 = 0.toFloat() -val element11 = 0.toDouble() -val element12 = 1.toByte() -val element13 = 1.toShort() -val element14 = 1 -val element15 = 1.toLong() -val element16 = 1.toFloat() -val element17 = 1.toDouble() -val element18 = 2.toByte() -val element19 = 2.toShort() -val element20 = 2 -val element21 = 2.toLong() -val element22 = 2.toFloat() -val element23 = 2.toDouble() -val element24 = 3.toByte() -val element25 = 3.toShort() -val element26 = 3 -val element27 = 3.toLong() -val element28 = 3.toFloat() -val element29 = 3.toDouble() -val element30 = 4.toByte() -val element31 = 4.toShort() -val element32 = 4 -val element33 = 4.toLong() -val element34 = 4.toFloat() -val element35 = 4.toDouble() +val element4 = 0.toByte() +val element5 = 0.toShort() +val element6 = 0 +val element7 = 0.toLong() +val element8 = 1.toByte() +val element9 = 1.toShort() +val element10 = 1 +val element11 = 1.toLong() +val element12 = 2.toByte() +val element13 = 2.toShort() +val element14 = 2 +val element15 = 2.toLong() +val element16 = 3.toByte() +val element17 = 3.toShort() +val element18 = 3 +val element19 = 3.toLong() +val element20 = 4.toByte() +val element21 = 4.toShort() +val element22 = 4 +val element23 = 4.toLong() fun box(): String { testR0xE0() @@ -70,18 +58,6 @@ fun box(): String { testR0xE21() testR0xE22() testR0xE23() - testR0xE24() - testR0xE25() - testR0xE26() - testR0xE27() - testR0xE28() - testR0xE29() - testR0xE30() - testR0xE31() - testR0xE32() - testR0xE33() - testR0xE34() - testR0xE35() testR1xE0() testR1xE1() testR1xE2() @@ -106,18 +82,6 @@ fun box(): String { testR1xE21() testR1xE22() testR1xE23() - testR1xE24() - testR1xE25() - testR1xE26() - testR1xE27() - testR1xE28() - testR1xE29() - testR1xE30() - testR1xE31() - testR1xE32() - testR1xE33() - testR1xE34() - testR1xE35() return "OK" } @@ -175,10 +139,10 @@ fun testR0xE3() { fun testR0xE4() { // with possible local optimizations - if ((-1).toFloat() in collection.indices != range0.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in collection.indices != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in collection.indices) != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in collection.indices) != range0.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in collection.indices != range0.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in collection.indices != !range0.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in collection.indices) != !range0.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in collection.indices) != range0.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in collection.indices != range0.contains(element4)) throw AssertionError() if (element4 !in collection.indices != !range0.contains(element4)) throw AssertionError() @@ -188,10 +152,10 @@ fun testR0xE4() { fun testR0xE5() { // with possible local optimizations - if ((-1).toDouble() in collection.indices != range0.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in collection.indices != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in collection.indices) != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in collection.indices) != range0.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in collection.indices != range0.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in collection.indices != !range0.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in collection.indices) != !range0.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in collection.indices) != range0.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in collection.indices != range0.contains(element5)) throw AssertionError() if (element5 !in collection.indices != !range0.contains(element5)) throw AssertionError() @@ -201,10 +165,10 @@ fun testR0xE5() { fun testR0xE6() { // with possible local optimizations - if (0.toByte() in collection.indices != range0.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in collection.indices != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in collection.indices) != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in collection.indices) != range0.contains(0.toByte())) throw AssertionError() + if (0 in collection.indices != range0.contains(0)) throw AssertionError() + if (0 !in collection.indices != !range0.contains(0)) throw AssertionError() + if (!(0 in collection.indices) != !range0.contains(0)) throw AssertionError() + if (!(0 !in collection.indices) != range0.contains(0)) throw AssertionError() // no local optimizations if (element6 in collection.indices != range0.contains(element6)) throw AssertionError() if (element6 !in collection.indices != !range0.contains(element6)) throw AssertionError() @@ -214,10 +178,10 @@ fun testR0xE6() { fun testR0xE7() { // with possible local optimizations - if (0.toShort() in collection.indices != range0.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in collection.indices != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in collection.indices) != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in collection.indices) != range0.contains(0.toShort())) throw AssertionError() + if (0.toLong() in collection.indices != range0.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in collection.indices != !range0.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in collection.indices) != !range0.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in collection.indices) != range0.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in collection.indices != range0.contains(element7)) throw AssertionError() if (element7 !in collection.indices != !range0.contains(element7)) throw AssertionError() @@ -227,10 +191,10 @@ fun testR0xE7() { fun testR0xE8() { // with possible local optimizations - if (0 in collection.indices != range0.contains(0)) throw AssertionError() - if (0 !in collection.indices != !range0.contains(0)) throw AssertionError() - if (!(0 in collection.indices) != !range0.contains(0)) throw AssertionError() - if (!(0 !in collection.indices) != range0.contains(0)) throw AssertionError() + if (1.toByte() in collection.indices != range0.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in collection.indices != !range0.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in collection.indices) != !range0.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in collection.indices) != range0.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in collection.indices != range0.contains(element8)) throw AssertionError() if (element8 !in collection.indices != !range0.contains(element8)) throw AssertionError() @@ -240,10 +204,10 @@ fun testR0xE8() { fun testR0xE9() { // with possible local optimizations - if (0.toLong() in collection.indices != range0.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in collection.indices != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in collection.indices) != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in collection.indices) != range0.contains(0.toLong())) throw AssertionError() + if (1.toShort() in collection.indices != range0.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in collection.indices != !range0.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in collection.indices) != !range0.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in collection.indices) != range0.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in collection.indices != range0.contains(element9)) throw AssertionError() if (element9 !in collection.indices != !range0.contains(element9)) throw AssertionError() @@ -253,10 +217,10 @@ fun testR0xE9() { fun testR0xE10() { // with possible local optimizations - if (0.toFloat() in collection.indices != range0.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in collection.indices != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in collection.indices) != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in collection.indices) != range0.contains(0.toFloat())) throw AssertionError() + if (1 in collection.indices != range0.contains(1)) throw AssertionError() + if (1 !in collection.indices != !range0.contains(1)) throw AssertionError() + if (!(1 in collection.indices) != !range0.contains(1)) throw AssertionError() + if (!(1 !in collection.indices) != range0.contains(1)) throw AssertionError() // no local optimizations if (element10 in collection.indices != range0.contains(element10)) throw AssertionError() if (element10 !in collection.indices != !range0.contains(element10)) throw AssertionError() @@ -266,10 +230,10 @@ fun testR0xE10() { fun testR0xE11() { // with possible local optimizations - if (0.toDouble() in collection.indices != range0.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in collection.indices != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in collection.indices) != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in collection.indices) != range0.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in collection.indices != range0.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in collection.indices != !range0.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in collection.indices) != !range0.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in collection.indices) != range0.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in collection.indices != range0.contains(element11)) throw AssertionError() if (element11 !in collection.indices != !range0.contains(element11)) throw AssertionError() @@ -279,10 +243,10 @@ fun testR0xE11() { fun testR0xE12() { // with possible local optimizations - if (1.toByte() in collection.indices != range0.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in collection.indices != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in collection.indices) != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in collection.indices) != range0.contains(1.toByte())) throw AssertionError() + if (2.toByte() in collection.indices != range0.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in collection.indices != !range0.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in collection.indices) != !range0.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in collection.indices) != range0.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in collection.indices != range0.contains(element12)) throw AssertionError() if (element12 !in collection.indices != !range0.contains(element12)) throw AssertionError() @@ -292,10 +256,10 @@ fun testR0xE12() { fun testR0xE13() { // with possible local optimizations - if (1.toShort() in collection.indices != range0.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in collection.indices != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in collection.indices) != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in collection.indices) != range0.contains(1.toShort())) throw AssertionError() + if (2.toShort() in collection.indices != range0.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in collection.indices != !range0.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in collection.indices) != !range0.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in collection.indices) != range0.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in collection.indices != range0.contains(element13)) throw AssertionError() if (element13 !in collection.indices != !range0.contains(element13)) throw AssertionError() @@ -305,10 +269,10 @@ fun testR0xE13() { fun testR0xE14() { // with possible local optimizations - if (1 in collection.indices != range0.contains(1)) throw AssertionError() - if (1 !in collection.indices != !range0.contains(1)) throw AssertionError() - if (!(1 in collection.indices) != !range0.contains(1)) throw AssertionError() - if (!(1 !in collection.indices) != range0.contains(1)) throw AssertionError() + if (2 in collection.indices != range0.contains(2)) throw AssertionError() + if (2 !in collection.indices != !range0.contains(2)) throw AssertionError() + if (!(2 in collection.indices) != !range0.contains(2)) throw AssertionError() + if (!(2 !in collection.indices) != range0.contains(2)) throw AssertionError() // no local optimizations if (element14 in collection.indices != range0.contains(element14)) throw AssertionError() if (element14 !in collection.indices != !range0.contains(element14)) throw AssertionError() @@ -318,10 +282,10 @@ fun testR0xE14() { fun testR0xE15() { // with possible local optimizations - if (1.toLong() in collection.indices != range0.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in collection.indices != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in collection.indices) != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in collection.indices) != range0.contains(1.toLong())) throw AssertionError() + if (2.toLong() in collection.indices != range0.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in collection.indices != !range0.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in collection.indices) != !range0.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in collection.indices) != range0.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in collection.indices != range0.contains(element15)) throw AssertionError() if (element15 !in collection.indices != !range0.contains(element15)) throw AssertionError() @@ -331,10 +295,10 @@ fun testR0xE15() { fun testR0xE16() { // with possible local optimizations - if (1.toFloat() in collection.indices != range0.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in collection.indices != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in collection.indices) != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in collection.indices) != range0.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in collection.indices != range0.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in collection.indices != !range0.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in collection.indices) != !range0.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in collection.indices) != range0.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in collection.indices != range0.contains(element16)) throw AssertionError() if (element16 !in collection.indices != !range0.contains(element16)) throw AssertionError() @@ -344,10 +308,10 @@ fun testR0xE16() { fun testR0xE17() { // with possible local optimizations - if (1.toDouble() in collection.indices != range0.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in collection.indices != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in collection.indices) != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in collection.indices) != range0.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in collection.indices != range0.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in collection.indices != !range0.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in collection.indices) != !range0.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in collection.indices) != range0.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in collection.indices != range0.contains(element17)) throw AssertionError() if (element17 !in collection.indices != !range0.contains(element17)) throw AssertionError() @@ -357,10 +321,10 @@ fun testR0xE17() { fun testR0xE18() { // with possible local optimizations - if (2.toByte() in collection.indices != range0.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in collection.indices != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in collection.indices) != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in collection.indices) != range0.contains(2.toByte())) throw AssertionError() + if (3 in collection.indices != range0.contains(3)) throw AssertionError() + if (3 !in collection.indices != !range0.contains(3)) throw AssertionError() + if (!(3 in collection.indices) != !range0.contains(3)) throw AssertionError() + if (!(3 !in collection.indices) != range0.contains(3)) throw AssertionError() // no local optimizations if (element18 in collection.indices != range0.contains(element18)) throw AssertionError() if (element18 !in collection.indices != !range0.contains(element18)) throw AssertionError() @@ -370,10 +334,10 @@ fun testR0xE18() { fun testR0xE19() { // with possible local optimizations - if (2.toShort() in collection.indices != range0.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in collection.indices != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in collection.indices) != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in collection.indices) != range0.contains(2.toShort())) throw AssertionError() + if (3.toLong() in collection.indices != range0.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in collection.indices != !range0.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in collection.indices) != !range0.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in collection.indices) != range0.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in collection.indices != range0.contains(element19)) throw AssertionError() if (element19 !in collection.indices != !range0.contains(element19)) throw AssertionError() @@ -383,10 +347,10 @@ fun testR0xE19() { fun testR0xE20() { // with possible local optimizations - if (2 in collection.indices != range0.contains(2)) throw AssertionError() - if (2 !in collection.indices != !range0.contains(2)) throw AssertionError() - if (!(2 in collection.indices) != !range0.contains(2)) throw AssertionError() - if (!(2 !in collection.indices) != range0.contains(2)) throw AssertionError() + if (4.toByte() in collection.indices != range0.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in collection.indices != !range0.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in collection.indices) != !range0.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in collection.indices) != range0.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in collection.indices != range0.contains(element20)) throw AssertionError() if (element20 !in collection.indices != !range0.contains(element20)) throw AssertionError() @@ -396,10 +360,10 @@ fun testR0xE20() { fun testR0xE21() { // with possible local optimizations - if (2.toLong() in collection.indices != range0.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in collection.indices != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in collection.indices) != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in collection.indices) != range0.contains(2.toLong())) throw AssertionError() + if (4.toShort() in collection.indices != range0.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in collection.indices != !range0.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in collection.indices) != !range0.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in collection.indices) != range0.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in collection.indices != range0.contains(element21)) throw AssertionError() if (element21 !in collection.indices != !range0.contains(element21)) throw AssertionError() @@ -409,10 +373,10 @@ fun testR0xE21() { fun testR0xE22() { // with possible local optimizations - if (2.toFloat() in collection.indices != range0.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in collection.indices != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in collection.indices) != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in collection.indices) != range0.contains(2.toFloat())) throw AssertionError() + if (4 in collection.indices != range0.contains(4)) throw AssertionError() + if (4 !in collection.indices != !range0.contains(4)) throw AssertionError() + if (!(4 in collection.indices) != !range0.contains(4)) throw AssertionError() + if (!(4 !in collection.indices) != range0.contains(4)) throw AssertionError() // no local optimizations if (element22 in collection.indices != range0.contains(element22)) throw AssertionError() if (element22 !in collection.indices != !range0.contains(element22)) throw AssertionError() @@ -421,172 +385,16 @@ fun testR0xE22() { } fun testR0xE23() { - // with possible local optimizations - if (2.toDouble() in collection.indices != range0.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in collection.indices != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in collection.indices) != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in collection.indices) != range0.contains(2.toDouble())) throw AssertionError() - // no local optimizations - if (element23 in collection.indices != range0.contains(element23)) throw AssertionError() - if (element23 !in collection.indices != !range0.contains(element23)) throw AssertionError() - if (!(element23 in collection.indices) != !range0.contains(element23)) throw AssertionError() - if (!(element23 !in collection.indices) != range0.contains(element23)) throw AssertionError() -} - -fun testR0xE24() { - // with possible local optimizations - if (3.toByte() in collection.indices != range0.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in collection.indices != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in collection.indices) != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in collection.indices) != range0.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in collection.indices != range0.contains(element24)) throw AssertionError() - if (element24 !in collection.indices != !range0.contains(element24)) throw AssertionError() - if (!(element24 in collection.indices) != !range0.contains(element24)) throw AssertionError() - if (!(element24 !in collection.indices) != range0.contains(element24)) throw AssertionError() -} - -fun testR0xE25() { - // with possible local optimizations - if (3.toShort() in collection.indices != range0.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in collection.indices != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in collection.indices) != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in collection.indices) != range0.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in collection.indices != range0.contains(element25)) throw AssertionError() - if (element25 !in collection.indices != !range0.contains(element25)) throw AssertionError() - if (!(element25 in collection.indices) != !range0.contains(element25)) throw AssertionError() - if (!(element25 !in collection.indices) != range0.contains(element25)) throw AssertionError() -} - -fun testR0xE26() { - // with possible local optimizations - if (3 in collection.indices != range0.contains(3)) throw AssertionError() - if (3 !in collection.indices != !range0.contains(3)) throw AssertionError() - if (!(3 in collection.indices) != !range0.contains(3)) throw AssertionError() - if (!(3 !in collection.indices) != range0.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in collection.indices != range0.contains(element26)) throw AssertionError() - if (element26 !in collection.indices != !range0.contains(element26)) throw AssertionError() - if (!(element26 in collection.indices) != !range0.contains(element26)) throw AssertionError() - if (!(element26 !in collection.indices) != range0.contains(element26)) throw AssertionError() -} - -fun testR0xE27() { - // with possible local optimizations - if (3.toLong() in collection.indices != range0.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in collection.indices != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in collection.indices) != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in collection.indices) != range0.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in collection.indices != range0.contains(element27)) throw AssertionError() - if (element27 !in collection.indices != !range0.contains(element27)) throw AssertionError() - if (!(element27 in collection.indices) != !range0.contains(element27)) throw AssertionError() - if (!(element27 !in collection.indices) != range0.contains(element27)) throw AssertionError() -} - -fun testR0xE28() { - // with possible local optimizations - if (3.toFloat() in collection.indices != range0.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in collection.indices != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in collection.indices) != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in collection.indices) != range0.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in collection.indices != range0.contains(element28)) throw AssertionError() - if (element28 !in collection.indices != !range0.contains(element28)) throw AssertionError() - if (!(element28 in collection.indices) != !range0.contains(element28)) throw AssertionError() - if (!(element28 !in collection.indices) != range0.contains(element28)) throw AssertionError() -} - -fun testR0xE29() { - // with possible local optimizations - if (3.toDouble() in collection.indices != range0.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in collection.indices != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in collection.indices) != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in collection.indices) != range0.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in collection.indices != range0.contains(element29)) throw AssertionError() - if (element29 !in collection.indices != !range0.contains(element29)) throw AssertionError() - if (!(element29 in collection.indices) != !range0.contains(element29)) throw AssertionError() - if (!(element29 !in collection.indices) != range0.contains(element29)) throw AssertionError() -} - -fun testR0xE30() { - // with possible local optimizations - if (4.toByte() in collection.indices != range0.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in collection.indices != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in collection.indices) != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in collection.indices) != range0.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in collection.indices != range0.contains(element30)) throw AssertionError() - if (element30 !in collection.indices != !range0.contains(element30)) throw AssertionError() - if (!(element30 in collection.indices) != !range0.contains(element30)) throw AssertionError() - if (!(element30 !in collection.indices) != range0.contains(element30)) throw AssertionError() -} - -fun testR0xE31() { - // with possible local optimizations - if (4.toShort() in collection.indices != range0.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in collection.indices != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in collection.indices) != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in collection.indices) != range0.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in collection.indices != range0.contains(element31)) throw AssertionError() - if (element31 !in collection.indices != !range0.contains(element31)) throw AssertionError() - if (!(element31 in collection.indices) != !range0.contains(element31)) throw AssertionError() - if (!(element31 !in collection.indices) != range0.contains(element31)) throw AssertionError() -} - -fun testR0xE32() { - // with possible local optimizations - if (4 in collection.indices != range0.contains(4)) throw AssertionError() - if (4 !in collection.indices != !range0.contains(4)) throw AssertionError() - if (!(4 in collection.indices) != !range0.contains(4)) throw AssertionError() - if (!(4 !in collection.indices) != range0.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in collection.indices != range0.contains(element32)) throw AssertionError() - if (element32 !in collection.indices != !range0.contains(element32)) throw AssertionError() - if (!(element32 in collection.indices) != !range0.contains(element32)) throw AssertionError() - if (!(element32 !in collection.indices) != range0.contains(element32)) throw AssertionError() -} - -fun testR0xE33() { // with possible local optimizations if (4.toLong() in collection.indices != range0.contains(4.toLong())) throw AssertionError() if (4.toLong() !in collection.indices != !range0.contains(4.toLong())) throw AssertionError() if (!(4.toLong() in collection.indices) != !range0.contains(4.toLong())) throw AssertionError() if (!(4.toLong() !in collection.indices) != range0.contains(4.toLong())) throw AssertionError() // no local optimizations - if (element33 in collection.indices != range0.contains(element33)) throw AssertionError() - if (element33 !in collection.indices != !range0.contains(element33)) throw AssertionError() - if (!(element33 in collection.indices) != !range0.contains(element33)) throw AssertionError() - if (!(element33 !in collection.indices) != range0.contains(element33)) throw AssertionError() -} - -fun testR0xE34() { - // with possible local optimizations - if (4.toFloat() in collection.indices != range0.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in collection.indices != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in collection.indices) != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in collection.indices) != range0.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in collection.indices != range0.contains(element34)) throw AssertionError() - if (element34 !in collection.indices != !range0.contains(element34)) throw AssertionError() - if (!(element34 in collection.indices) != !range0.contains(element34)) throw AssertionError() - if (!(element34 !in collection.indices) != range0.contains(element34)) throw AssertionError() -} - -fun testR0xE35() { - // with possible local optimizations - if (4.toDouble() in collection.indices != range0.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in collection.indices != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in collection.indices) != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in collection.indices) != range0.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in collection.indices != range0.contains(element35)) throw AssertionError() - if (element35 !in collection.indices != !range0.contains(element35)) throw AssertionError() - if (!(element35 in collection.indices) != !range0.contains(element35)) throw AssertionError() - if (!(element35 !in collection.indices) != range0.contains(element35)) throw AssertionError() + if (element23 in collection.indices != range0.contains(element23)) throw AssertionError() + if (element23 !in collection.indices != !range0.contains(element23)) throw AssertionError() + if (!(element23 in collection.indices) != !range0.contains(element23)) throw AssertionError() + if (!(element23 !in collection.indices) != range0.contains(element23)) throw AssertionError() } fun testR1xE0() { @@ -643,10 +451,10 @@ fun testR1xE3() { fun testR1xE4() { // with possible local optimizations - if ((-1).toFloat() in emptyCollection.indices != range1.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in emptyCollection.indices != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in emptyCollection.indices) != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in emptyCollection.indices) != range1.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in emptyCollection.indices != range1.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in emptyCollection.indices != !range1.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in emptyCollection.indices) != !range1.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in emptyCollection.indices) != range1.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in emptyCollection.indices != range1.contains(element4)) throw AssertionError() if (element4 !in emptyCollection.indices != !range1.contains(element4)) throw AssertionError() @@ -656,10 +464,10 @@ fun testR1xE4() { fun testR1xE5() { // with possible local optimizations - if ((-1).toDouble() in emptyCollection.indices != range1.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in emptyCollection.indices != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in emptyCollection.indices) != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in emptyCollection.indices) != range1.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in emptyCollection.indices != range1.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in emptyCollection.indices != !range1.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in emptyCollection.indices) != !range1.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in emptyCollection.indices) != range1.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in emptyCollection.indices != range1.contains(element5)) throw AssertionError() if (element5 !in emptyCollection.indices != !range1.contains(element5)) throw AssertionError() @@ -669,10 +477,10 @@ fun testR1xE5() { fun testR1xE6() { // with possible local optimizations - if (0.toByte() in emptyCollection.indices != range1.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in emptyCollection.indices != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in emptyCollection.indices) != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in emptyCollection.indices) != range1.contains(0.toByte())) throw AssertionError() + if (0 in emptyCollection.indices != range1.contains(0)) throw AssertionError() + if (0 !in emptyCollection.indices != !range1.contains(0)) throw AssertionError() + if (!(0 in emptyCollection.indices) != !range1.contains(0)) throw AssertionError() + if (!(0 !in emptyCollection.indices) != range1.contains(0)) throw AssertionError() // no local optimizations if (element6 in emptyCollection.indices != range1.contains(element6)) throw AssertionError() if (element6 !in emptyCollection.indices != !range1.contains(element6)) throw AssertionError() @@ -682,10 +490,10 @@ fun testR1xE6() { fun testR1xE7() { // with possible local optimizations - if (0.toShort() in emptyCollection.indices != range1.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in emptyCollection.indices != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in emptyCollection.indices) != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in emptyCollection.indices) != range1.contains(0.toShort())) throw AssertionError() + if (0.toLong() in emptyCollection.indices != range1.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in emptyCollection.indices != !range1.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in emptyCollection.indices) != !range1.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in emptyCollection.indices) != range1.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in emptyCollection.indices != range1.contains(element7)) throw AssertionError() if (element7 !in emptyCollection.indices != !range1.contains(element7)) throw AssertionError() @@ -695,10 +503,10 @@ fun testR1xE7() { fun testR1xE8() { // with possible local optimizations - if (0 in emptyCollection.indices != range1.contains(0)) throw AssertionError() - if (0 !in emptyCollection.indices != !range1.contains(0)) throw AssertionError() - if (!(0 in emptyCollection.indices) != !range1.contains(0)) throw AssertionError() - if (!(0 !in emptyCollection.indices) != range1.contains(0)) throw AssertionError() + if (1.toByte() in emptyCollection.indices != range1.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in emptyCollection.indices != !range1.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in emptyCollection.indices) != !range1.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in emptyCollection.indices) != range1.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in emptyCollection.indices != range1.contains(element8)) throw AssertionError() if (element8 !in emptyCollection.indices != !range1.contains(element8)) throw AssertionError() @@ -708,10 +516,10 @@ fun testR1xE8() { fun testR1xE9() { // with possible local optimizations - if (0.toLong() in emptyCollection.indices != range1.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in emptyCollection.indices != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in emptyCollection.indices) != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in emptyCollection.indices) != range1.contains(0.toLong())) throw AssertionError() + if (1.toShort() in emptyCollection.indices != range1.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in emptyCollection.indices != !range1.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in emptyCollection.indices) != !range1.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in emptyCollection.indices) != range1.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in emptyCollection.indices != range1.contains(element9)) throw AssertionError() if (element9 !in emptyCollection.indices != !range1.contains(element9)) throw AssertionError() @@ -721,10 +529,10 @@ fun testR1xE9() { fun testR1xE10() { // with possible local optimizations - if (0.toFloat() in emptyCollection.indices != range1.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in emptyCollection.indices != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in emptyCollection.indices) != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in emptyCollection.indices) != range1.contains(0.toFloat())) throw AssertionError() + if (1 in emptyCollection.indices != range1.contains(1)) throw AssertionError() + if (1 !in emptyCollection.indices != !range1.contains(1)) throw AssertionError() + if (!(1 in emptyCollection.indices) != !range1.contains(1)) throw AssertionError() + if (!(1 !in emptyCollection.indices) != range1.contains(1)) throw AssertionError() // no local optimizations if (element10 in emptyCollection.indices != range1.contains(element10)) throw AssertionError() if (element10 !in emptyCollection.indices != !range1.contains(element10)) throw AssertionError() @@ -734,10 +542,10 @@ fun testR1xE10() { fun testR1xE11() { // with possible local optimizations - if (0.toDouble() in emptyCollection.indices != range1.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in emptyCollection.indices != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in emptyCollection.indices) != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in emptyCollection.indices) != range1.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in emptyCollection.indices != range1.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in emptyCollection.indices != !range1.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in emptyCollection.indices) != !range1.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in emptyCollection.indices) != range1.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in emptyCollection.indices != range1.contains(element11)) throw AssertionError() if (element11 !in emptyCollection.indices != !range1.contains(element11)) throw AssertionError() @@ -747,10 +555,10 @@ fun testR1xE11() { fun testR1xE12() { // with possible local optimizations - if (1.toByte() in emptyCollection.indices != range1.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in emptyCollection.indices != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in emptyCollection.indices) != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in emptyCollection.indices) != range1.contains(1.toByte())) throw AssertionError() + if (2.toByte() in emptyCollection.indices != range1.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in emptyCollection.indices != !range1.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in emptyCollection.indices) != !range1.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in emptyCollection.indices) != range1.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in emptyCollection.indices != range1.contains(element12)) throw AssertionError() if (element12 !in emptyCollection.indices != !range1.contains(element12)) throw AssertionError() @@ -760,10 +568,10 @@ fun testR1xE12() { fun testR1xE13() { // with possible local optimizations - if (1.toShort() in emptyCollection.indices != range1.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in emptyCollection.indices != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in emptyCollection.indices) != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in emptyCollection.indices) != range1.contains(1.toShort())) throw AssertionError() + if (2.toShort() in emptyCollection.indices != range1.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in emptyCollection.indices != !range1.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in emptyCollection.indices) != !range1.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in emptyCollection.indices) != range1.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in emptyCollection.indices != range1.contains(element13)) throw AssertionError() if (element13 !in emptyCollection.indices != !range1.contains(element13)) throw AssertionError() @@ -773,10 +581,10 @@ fun testR1xE13() { fun testR1xE14() { // with possible local optimizations - if (1 in emptyCollection.indices != range1.contains(1)) throw AssertionError() - if (1 !in emptyCollection.indices != !range1.contains(1)) throw AssertionError() - if (!(1 in emptyCollection.indices) != !range1.contains(1)) throw AssertionError() - if (!(1 !in emptyCollection.indices) != range1.contains(1)) throw AssertionError() + if (2 in emptyCollection.indices != range1.contains(2)) throw AssertionError() + if (2 !in emptyCollection.indices != !range1.contains(2)) throw AssertionError() + if (!(2 in emptyCollection.indices) != !range1.contains(2)) throw AssertionError() + if (!(2 !in emptyCollection.indices) != range1.contains(2)) throw AssertionError() // no local optimizations if (element14 in emptyCollection.indices != range1.contains(element14)) throw AssertionError() if (element14 !in emptyCollection.indices != !range1.contains(element14)) throw AssertionError() @@ -786,10 +594,10 @@ fun testR1xE14() { fun testR1xE15() { // with possible local optimizations - if (1.toLong() in emptyCollection.indices != range1.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in emptyCollection.indices != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in emptyCollection.indices) != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in emptyCollection.indices) != range1.contains(1.toLong())) throw AssertionError() + if (2.toLong() in emptyCollection.indices != range1.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in emptyCollection.indices != !range1.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in emptyCollection.indices) != !range1.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in emptyCollection.indices) != range1.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in emptyCollection.indices != range1.contains(element15)) throw AssertionError() if (element15 !in emptyCollection.indices != !range1.contains(element15)) throw AssertionError() @@ -799,10 +607,10 @@ fun testR1xE15() { fun testR1xE16() { // with possible local optimizations - if (1.toFloat() in emptyCollection.indices != range1.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in emptyCollection.indices != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in emptyCollection.indices) != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in emptyCollection.indices) != range1.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in emptyCollection.indices != range1.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in emptyCollection.indices != !range1.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in emptyCollection.indices) != !range1.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in emptyCollection.indices) != range1.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in emptyCollection.indices != range1.contains(element16)) throw AssertionError() if (element16 !in emptyCollection.indices != !range1.contains(element16)) throw AssertionError() @@ -812,10 +620,10 @@ fun testR1xE16() { fun testR1xE17() { // with possible local optimizations - if (1.toDouble() in emptyCollection.indices != range1.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in emptyCollection.indices != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in emptyCollection.indices) != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in emptyCollection.indices) != range1.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in emptyCollection.indices != range1.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in emptyCollection.indices != !range1.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in emptyCollection.indices) != !range1.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in emptyCollection.indices) != range1.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in emptyCollection.indices != range1.contains(element17)) throw AssertionError() if (element17 !in emptyCollection.indices != !range1.contains(element17)) throw AssertionError() @@ -825,10 +633,10 @@ fun testR1xE17() { fun testR1xE18() { // with possible local optimizations - if (2.toByte() in emptyCollection.indices != range1.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in emptyCollection.indices != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in emptyCollection.indices) != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in emptyCollection.indices) != range1.contains(2.toByte())) throw AssertionError() + if (3 in emptyCollection.indices != range1.contains(3)) throw AssertionError() + if (3 !in emptyCollection.indices != !range1.contains(3)) throw AssertionError() + if (!(3 in emptyCollection.indices) != !range1.contains(3)) throw AssertionError() + if (!(3 !in emptyCollection.indices) != range1.contains(3)) throw AssertionError() // no local optimizations if (element18 in emptyCollection.indices != range1.contains(element18)) throw AssertionError() if (element18 !in emptyCollection.indices != !range1.contains(element18)) throw AssertionError() @@ -838,10 +646,10 @@ fun testR1xE18() { fun testR1xE19() { // with possible local optimizations - if (2.toShort() in emptyCollection.indices != range1.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in emptyCollection.indices != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in emptyCollection.indices) != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in emptyCollection.indices) != range1.contains(2.toShort())) throw AssertionError() + if (3.toLong() in emptyCollection.indices != range1.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in emptyCollection.indices != !range1.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in emptyCollection.indices) != !range1.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in emptyCollection.indices) != range1.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in emptyCollection.indices != range1.contains(element19)) throw AssertionError() if (element19 !in emptyCollection.indices != !range1.contains(element19)) throw AssertionError() @@ -851,10 +659,10 @@ fun testR1xE19() { fun testR1xE20() { // with possible local optimizations - if (2 in emptyCollection.indices != range1.contains(2)) throw AssertionError() - if (2 !in emptyCollection.indices != !range1.contains(2)) throw AssertionError() - if (!(2 in emptyCollection.indices) != !range1.contains(2)) throw AssertionError() - if (!(2 !in emptyCollection.indices) != range1.contains(2)) throw AssertionError() + if (4.toByte() in emptyCollection.indices != range1.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in emptyCollection.indices != !range1.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in emptyCollection.indices) != !range1.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in emptyCollection.indices) != range1.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in emptyCollection.indices != range1.contains(element20)) throw AssertionError() if (element20 !in emptyCollection.indices != !range1.contains(element20)) throw AssertionError() @@ -864,10 +672,10 @@ fun testR1xE20() { fun testR1xE21() { // with possible local optimizations - if (2.toLong() in emptyCollection.indices != range1.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in emptyCollection.indices != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in emptyCollection.indices) != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in emptyCollection.indices) != range1.contains(2.toLong())) throw AssertionError() + if (4.toShort() in emptyCollection.indices != range1.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in emptyCollection.indices != !range1.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in emptyCollection.indices) != !range1.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in emptyCollection.indices) != range1.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in emptyCollection.indices != range1.contains(element21)) throw AssertionError() if (element21 !in emptyCollection.indices != !range1.contains(element21)) throw AssertionError() @@ -877,10 +685,10 @@ fun testR1xE21() { fun testR1xE22() { // with possible local optimizations - if (2.toFloat() in emptyCollection.indices != range1.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in emptyCollection.indices != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in emptyCollection.indices) != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in emptyCollection.indices) != range1.contains(2.toFloat())) throw AssertionError() + if (4 in emptyCollection.indices != range1.contains(4)) throw AssertionError() + if (4 !in emptyCollection.indices != !range1.contains(4)) throw AssertionError() + if (!(4 in emptyCollection.indices) != !range1.contains(4)) throw AssertionError() + if (!(4 !in emptyCollection.indices) != range1.contains(4)) throw AssertionError() // no local optimizations if (element22 in emptyCollection.indices != range1.contains(element22)) throw AssertionError() if (element22 !in emptyCollection.indices != !range1.contains(element22)) throw AssertionError() @@ -890,10 +698,10 @@ fun testR1xE22() { fun testR1xE23() { // with possible local optimizations - if (2.toDouble() in emptyCollection.indices != range1.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in emptyCollection.indices != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in emptyCollection.indices) != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in emptyCollection.indices) != range1.contains(2.toDouble())) throw AssertionError() + if (4.toLong() in emptyCollection.indices != range1.contains(4.toLong())) throw AssertionError() + if (4.toLong() !in emptyCollection.indices != !range1.contains(4.toLong())) throw AssertionError() + if (!(4.toLong() in emptyCollection.indices) != !range1.contains(4.toLong())) throw AssertionError() + if (!(4.toLong() !in emptyCollection.indices) != range1.contains(4.toLong())) throw AssertionError() // no local optimizations if (element23 in emptyCollection.indices != range1.contains(element23)) throw AssertionError() if (element23 !in emptyCollection.indices != !range1.contains(element23)) throw AssertionError() @@ -901,160 +709,4 @@ fun testR1xE23() { if (!(element23 !in emptyCollection.indices) != range1.contains(element23)) throw AssertionError() } -fun testR1xE24() { - // with possible local optimizations - if (3.toByte() in emptyCollection.indices != range1.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in emptyCollection.indices != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in emptyCollection.indices) != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in emptyCollection.indices) != range1.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in emptyCollection.indices != range1.contains(element24)) throw AssertionError() - if (element24 !in emptyCollection.indices != !range1.contains(element24)) throw AssertionError() - if (!(element24 in emptyCollection.indices) != !range1.contains(element24)) throw AssertionError() - if (!(element24 !in emptyCollection.indices) != range1.contains(element24)) throw AssertionError() -} - -fun testR1xE25() { - // with possible local optimizations - if (3.toShort() in emptyCollection.indices != range1.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in emptyCollection.indices != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in emptyCollection.indices) != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in emptyCollection.indices) != range1.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in emptyCollection.indices != range1.contains(element25)) throw AssertionError() - if (element25 !in emptyCollection.indices != !range1.contains(element25)) throw AssertionError() - if (!(element25 in emptyCollection.indices) != !range1.contains(element25)) throw AssertionError() - if (!(element25 !in emptyCollection.indices) != range1.contains(element25)) throw AssertionError() -} - -fun testR1xE26() { - // with possible local optimizations - if (3 in emptyCollection.indices != range1.contains(3)) throw AssertionError() - if (3 !in emptyCollection.indices != !range1.contains(3)) throw AssertionError() - if (!(3 in emptyCollection.indices) != !range1.contains(3)) throw AssertionError() - if (!(3 !in emptyCollection.indices) != range1.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in emptyCollection.indices != range1.contains(element26)) throw AssertionError() - if (element26 !in emptyCollection.indices != !range1.contains(element26)) throw AssertionError() - if (!(element26 in emptyCollection.indices) != !range1.contains(element26)) throw AssertionError() - if (!(element26 !in emptyCollection.indices) != range1.contains(element26)) throw AssertionError() -} - -fun testR1xE27() { - // with possible local optimizations - if (3.toLong() in emptyCollection.indices != range1.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in emptyCollection.indices != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in emptyCollection.indices) != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in emptyCollection.indices) != range1.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in emptyCollection.indices != range1.contains(element27)) throw AssertionError() - if (element27 !in emptyCollection.indices != !range1.contains(element27)) throw AssertionError() - if (!(element27 in emptyCollection.indices) != !range1.contains(element27)) throw AssertionError() - if (!(element27 !in emptyCollection.indices) != range1.contains(element27)) throw AssertionError() -} - -fun testR1xE28() { - // with possible local optimizations - if (3.toFloat() in emptyCollection.indices != range1.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in emptyCollection.indices != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in emptyCollection.indices) != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in emptyCollection.indices) != range1.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in emptyCollection.indices != range1.contains(element28)) throw AssertionError() - if (element28 !in emptyCollection.indices != !range1.contains(element28)) throw AssertionError() - if (!(element28 in emptyCollection.indices) != !range1.contains(element28)) throw AssertionError() - if (!(element28 !in emptyCollection.indices) != range1.contains(element28)) throw AssertionError() -} - -fun testR1xE29() { - // with possible local optimizations - if (3.toDouble() in emptyCollection.indices != range1.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in emptyCollection.indices != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in emptyCollection.indices) != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in emptyCollection.indices) != range1.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in emptyCollection.indices != range1.contains(element29)) throw AssertionError() - if (element29 !in emptyCollection.indices != !range1.contains(element29)) throw AssertionError() - if (!(element29 in emptyCollection.indices) != !range1.contains(element29)) throw AssertionError() - if (!(element29 !in emptyCollection.indices) != range1.contains(element29)) throw AssertionError() -} - -fun testR1xE30() { - // with possible local optimizations - if (4.toByte() in emptyCollection.indices != range1.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in emptyCollection.indices != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in emptyCollection.indices) != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in emptyCollection.indices) != range1.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in emptyCollection.indices != range1.contains(element30)) throw AssertionError() - if (element30 !in emptyCollection.indices != !range1.contains(element30)) throw AssertionError() - if (!(element30 in emptyCollection.indices) != !range1.contains(element30)) throw AssertionError() - if (!(element30 !in emptyCollection.indices) != range1.contains(element30)) throw AssertionError() -} - -fun testR1xE31() { - // with possible local optimizations - if (4.toShort() in emptyCollection.indices != range1.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in emptyCollection.indices != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in emptyCollection.indices) != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in emptyCollection.indices) != range1.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in emptyCollection.indices != range1.contains(element31)) throw AssertionError() - if (element31 !in emptyCollection.indices != !range1.contains(element31)) throw AssertionError() - if (!(element31 in emptyCollection.indices) != !range1.contains(element31)) throw AssertionError() - if (!(element31 !in emptyCollection.indices) != range1.contains(element31)) throw AssertionError() -} - -fun testR1xE32() { - // with possible local optimizations - if (4 in emptyCollection.indices != range1.contains(4)) throw AssertionError() - if (4 !in emptyCollection.indices != !range1.contains(4)) throw AssertionError() - if (!(4 in emptyCollection.indices) != !range1.contains(4)) throw AssertionError() - if (!(4 !in emptyCollection.indices) != range1.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in emptyCollection.indices != range1.contains(element32)) throw AssertionError() - if (element32 !in emptyCollection.indices != !range1.contains(element32)) throw AssertionError() - if (!(element32 in emptyCollection.indices) != !range1.contains(element32)) throw AssertionError() - if (!(element32 !in emptyCollection.indices) != range1.contains(element32)) throw AssertionError() -} - -fun testR1xE33() { - // with possible local optimizations - if (4.toLong() in emptyCollection.indices != range1.contains(4.toLong())) throw AssertionError() - if (4.toLong() !in emptyCollection.indices != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() in emptyCollection.indices) != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() !in emptyCollection.indices) != range1.contains(4.toLong())) throw AssertionError() - // no local optimizations - if (element33 in emptyCollection.indices != range1.contains(element33)) throw AssertionError() - if (element33 !in emptyCollection.indices != !range1.contains(element33)) throw AssertionError() - if (!(element33 in emptyCollection.indices) != !range1.contains(element33)) throw AssertionError() - if (!(element33 !in emptyCollection.indices) != range1.contains(element33)) throw AssertionError() -} - -fun testR1xE34() { - // with possible local optimizations - if (4.toFloat() in emptyCollection.indices != range1.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in emptyCollection.indices != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in emptyCollection.indices) != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in emptyCollection.indices) != range1.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in emptyCollection.indices != range1.contains(element34)) throw AssertionError() - if (element34 !in emptyCollection.indices != !range1.contains(element34)) throw AssertionError() - if (!(element34 in emptyCollection.indices) != !range1.contains(element34)) throw AssertionError() - if (!(element34 !in emptyCollection.indices) != range1.contains(element34)) throw AssertionError() -} - -fun testR1xE35() { - // with possible local optimizations - if (4.toDouble() in emptyCollection.indices != range1.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in emptyCollection.indices != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in emptyCollection.indices) != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in emptyCollection.indices) != range1.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in emptyCollection.indices != range1.contains(element35)) throw AssertionError() - if (element35 !in emptyCollection.indices != !range1.contains(element35)) throw AssertionError() - if (!(element35 in emptyCollection.indices) != !range1.contains(element35)) throw AssertionError() - if (!(element35 !in emptyCollection.indices) != range1.contains(element35)) throw AssertionError() -} - diff --git a/compiler/testData/codegen/box/ranges/contains/generated/doubleRangeLiteral.kt b/compiler/testData/codegen/box/ranges/contains/generated/doubleRangeLiteral.kt index ad0844ad2a4..870f87b1589 100644 --- a/compiler/testData/codegen/box/ranges/contains/generated/doubleRangeLiteral.kt +++ b/compiler/testData/codegen/box/ranges/contains/generated/doubleRangeLiteral.kt @@ -7,42 +7,18 @@ val range0 = 1.0 .. 3.0 val range1 = 3.0 .. 1.0 -val element0 = (-1).toByte() -val element1 = (-1).toShort() -val element2 = (-1) -val element3 = (-1).toLong() -val element4 = (-1).toFloat() -val element5 = (-1).toDouble() -val element6 = 0.toByte() -val element7 = 0.toShort() -val element8 = 0 -val element9 = 0.toLong() -val element10 = 0.toFloat() -val element11 = 0.toDouble() -val element12 = 1.toByte() -val element13 = 1.toShort() -val element14 = 1 -val element15 = 1.toLong() -val element16 = 1.toFloat() -val element17 = 1.toDouble() -val element18 = 2.toByte() -val element19 = 2.toShort() -val element20 = 2 -val element21 = 2.toLong() -val element22 = 2.toFloat() -val element23 = 2.toDouble() -val element24 = 3.toByte() -val element25 = 3.toShort() -val element26 = 3 -val element27 = 3.toLong() -val element28 = 3.toFloat() -val element29 = 3.toDouble() -val element30 = 4.toByte() -val element31 = 4.toShort() -val element32 = 4 -val element33 = 4.toLong() -val element34 = 4.toFloat() -val element35 = 4.toDouble() +val element0 = (-1).toFloat() +val element1 = (-1).toDouble() +val element2 = 0.toFloat() +val element3 = 0.toDouble() +val element4 = 1.toFloat() +val element5 = 1.toDouble() +val element6 = 2.toFloat() +val element7 = 2.toDouble() +val element8 = 3.toFloat() +val element9 = 3.toDouble() +val element10 = 4.toFloat() +val element11 = 4.toDouble() fun box(): String { testR0xE0() @@ -57,30 +33,6 @@ fun box(): String { testR0xE9() testR0xE10() testR0xE11() - testR0xE12() - testR0xE13() - testR0xE14() - testR0xE15() - testR0xE16() - testR0xE17() - testR0xE18() - testR0xE19() - testR0xE20() - testR0xE21() - testR0xE22() - testR0xE23() - testR0xE24() - testR0xE25() - testR0xE26() - testR0xE27() - testR0xE28() - testR0xE29() - testR0xE30() - testR0xE31() - testR0xE32() - testR0xE33() - testR0xE34() - testR0xE35() testR1xE0() testR1xE1() testR1xE2() @@ -93,39 +45,15 @@ fun box(): String { testR1xE9() testR1xE10() testR1xE11() - testR1xE12() - testR1xE13() - testR1xE14() - testR1xE15() - testR1xE16() - testR1xE17() - testR1xE18() - testR1xE19() - testR1xE20() - testR1xE21() - testR1xE22() - testR1xE23() - testR1xE24() - testR1xE25() - testR1xE26() - testR1xE27() - testR1xE28() - testR1xE29() - testR1xE30() - testR1xE31() - testR1xE32() - testR1xE33() - testR1xE34() - testR1xE35() return "OK" } fun testR0xE0() { // with possible local optimizations - if ((-1).toByte() in 1.0 .. 3.0 != range0.contains((-1).toByte())) throw AssertionError() - if ((-1).toByte() !in 1.0 .. 3.0 != !range0.contains((-1).toByte())) throw AssertionError() - if (!((-1).toByte() in 1.0 .. 3.0) != !range0.contains((-1).toByte())) throw AssertionError() - if (!((-1).toByte() !in 1.0 .. 3.0) != range0.contains((-1).toByte())) throw AssertionError() + if ((-1).toFloat() in 1.0 .. 3.0 != range0.contains((-1).toFloat())) throw AssertionError() + if ((-1).toFloat() !in 1.0 .. 3.0 != !range0.contains((-1).toFloat())) throw AssertionError() + if (!((-1).toFloat() in 1.0 .. 3.0) != !range0.contains((-1).toFloat())) throw AssertionError() + if (!((-1).toFloat() !in 1.0 .. 3.0) != range0.contains((-1).toFloat())) throw AssertionError() // no local optimizations if (element0 in 1.0 .. 3.0 != range0.contains(element0)) throw AssertionError() if (element0 !in 1.0 .. 3.0 != !range0.contains(element0)) throw AssertionError() @@ -135,10 +63,10 @@ fun testR0xE0() { fun testR0xE1() { // with possible local optimizations - if ((-1).toShort() in 1.0 .. 3.0 != range0.contains((-1).toShort())) throw AssertionError() - if ((-1).toShort() !in 1.0 .. 3.0 != !range0.contains((-1).toShort())) throw AssertionError() - if (!((-1).toShort() in 1.0 .. 3.0) != !range0.contains((-1).toShort())) throw AssertionError() - if (!((-1).toShort() !in 1.0 .. 3.0) != range0.contains((-1).toShort())) throw AssertionError() + if ((-1).toDouble() in 1.0 .. 3.0 != range0.contains((-1).toDouble())) throw AssertionError() + if ((-1).toDouble() !in 1.0 .. 3.0 != !range0.contains((-1).toDouble())) throw AssertionError() + if (!((-1).toDouble() in 1.0 .. 3.0) != !range0.contains((-1).toDouble())) throw AssertionError() + if (!((-1).toDouble() !in 1.0 .. 3.0) != range0.contains((-1).toDouble())) throw AssertionError() // no local optimizations if (element1 in 1.0 .. 3.0 != range0.contains(element1)) throw AssertionError() if (element1 !in 1.0 .. 3.0 != !range0.contains(element1)) throw AssertionError() @@ -148,10 +76,10 @@ fun testR0xE1() { fun testR0xE2() { // with possible local optimizations - if ((-1) in 1.0 .. 3.0 != range0.contains((-1))) throw AssertionError() - if ((-1) !in 1.0 .. 3.0 != !range0.contains((-1))) throw AssertionError() - if (!((-1) in 1.0 .. 3.0) != !range0.contains((-1))) throw AssertionError() - if (!((-1) !in 1.0 .. 3.0) != range0.contains((-1))) throw AssertionError() + if (0.toFloat() in 1.0 .. 3.0 != range0.contains(0.toFloat())) throw AssertionError() + if (0.toFloat() !in 1.0 .. 3.0 != !range0.contains(0.toFloat())) throw AssertionError() + if (!(0.toFloat() in 1.0 .. 3.0) != !range0.contains(0.toFloat())) throw AssertionError() + if (!(0.toFloat() !in 1.0 .. 3.0) != range0.contains(0.toFloat())) throw AssertionError() // no local optimizations if (element2 in 1.0 .. 3.0 != range0.contains(element2)) throw AssertionError() if (element2 !in 1.0 .. 3.0 != !range0.contains(element2)) throw AssertionError() @@ -161,10 +89,10 @@ fun testR0xE2() { fun testR0xE3() { // with possible local optimizations - if ((-1).toLong() in 1.0 .. 3.0 != range0.contains((-1).toLong())) throw AssertionError() - if ((-1).toLong() !in 1.0 .. 3.0 != !range0.contains((-1).toLong())) throw AssertionError() - if (!((-1).toLong() in 1.0 .. 3.0) != !range0.contains((-1).toLong())) throw AssertionError() - if (!((-1).toLong() !in 1.0 .. 3.0) != range0.contains((-1).toLong())) throw AssertionError() + if (0.toDouble() in 1.0 .. 3.0 != range0.contains(0.toDouble())) throw AssertionError() + if (0.toDouble() !in 1.0 .. 3.0 != !range0.contains(0.toDouble())) throw AssertionError() + if (!(0.toDouble() in 1.0 .. 3.0) != !range0.contains(0.toDouble())) throw AssertionError() + if (!(0.toDouble() !in 1.0 .. 3.0) != range0.contains(0.toDouble())) throw AssertionError() // no local optimizations if (element3 in 1.0 .. 3.0 != range0.contains(element3)) throw AssertionError() if (element3 !in 1.0 .. 3.0 != !range0.contains(element3)) throw AssertionError() @@ -174,10 +102,10 @@ fun testR0xE3() { fun testR0xE4() { // with possible local optimizations - if ((-1).toFloat() in 1.0 .. 3.0 != range0.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in 1.0 .. 3.0 != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in 1.0 .. 3.0) != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in 1.0 .. 3.0) != range0.contains((-1).toFloat())) throw AssertionError() + if (1.toFloat() in 1.0 .. 3.0 != range0.contains(1.toFloat())) throw AssertionError() + if (1.toFloat() !in 1.0 .. 3.0 != !range0.contains(1.toFloat())) throw AssertionError() + if (!(1.toFloat() in 1.0 .. 3.0) != !range0.contains(1.toFloat())) throw AssertionError() + if (!(1.toFloat() !in 1.0 .. 3.0) != range0.contains(1.toFloat())) throw AssertionError() // no local optimizations if (element4 in 1.0 .. 3.0 != range0.contains(element4)) throw AssertionError() if (element4 !in 1.0 .. 3.0 != !range0.contains(element4)) throw AssertionError() @@ -187,10 +115,10 @@ fun testR0xE4() { fun testR0xE5() { // with possible local optimizations - if ((-1).toDouble() in 1.0 .. 3.0 != range0.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in 1.0 .. 3.0 != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in 1.0 .. 3.0) != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in 1.0 .. 3.0) != range0.contains((-1).toDouble())) throw AssertionError() + if (1.toDouble() in 1.0 .. 3.0 != range0.contains(1.toDouble())) throw AssertionError() + if (1.toDouble() !in 1.0 .. 3.0 != !range0.contains(1.toDouble())) throw AssertionError() + if (!(1.toDouble() in 1.0 .. 3.0) != !range0.contains(1.toDouble())) throw AssertionError() + if (!(1.toDouble() !in 1.0 .. 3.0) != range0.contains(1.toDouble())) throw AssertionError() // no local optimizations if (element5 in 1.0 .. 3.0 != range0.contains(element5)) throw AssertionError() if (element5 !in 1.0 .. 3.0 != !range0.contains(element5)) throw AssertionError() @@ -200,10 +128,10 @@ fun testR0xE5() { fun testR0xE6() { // with possible local optimizations - if (0.toByte() in 1.0 .. 3.0 != range0.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in 1.0 .. 3.0 != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in 1.0 .. 3.0) != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in 1.0 .. 3.0) != range0.contains(0.toByte())) throw AssertionError() + if (2.toFloat() in 1.0 .. 3.0 != range0.contains(2.toFloat())) throw AssertionError() + if (2.toFloat() !in 1.0 .. 3.0 != !range0.contains(2.toFloat())) throw AssertionError() + if (!(2.toFloat() in 1.0 .. 3.0) != !range0.contains(2.toFloat())) throw AssertionError() + if (!(2.toFloat() !in 1.0 .. 3.0) != range0.contains(2.toFloat())) throw AssertionError() // no local optimizations if (element6 in 1.0 .. 3.0 != range0.contains(element6)) throw AssertionError() if (element6 !in 1.0 .. 3.0 != !range0.contains(element6)) throw AssertionError() @@ -213,10 +141,10 @@ fun testR0xE6() { fun testR0xE7() { // with possible local optimizations - if (0.toShort() in 1.0 .. 3.0 != range0.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in 1.0 .. 3.0 != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in 1.0 .. 3.0) != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in 1.0 .. 3.0) != range0.contains(0.toShort())) throw AssertionError() + if (2.toDouble() in 1.0 .. 3.0 != range0.contains(2.toDouble())) throw AssertionError() + if (2.toDouble() !in 1.0 .. 3.0 != !range0.contains(2.toDouble())) throw AssertionError() + if (!(2.toDouble() in 1.0 .. 3.0) != !range0.contains(2.toDouble())) throw AssertionError() + if (!(2.toDouble() !in 1.0 .. 3.0) != range0.contains(2.toDouble())) throw AssertionError() // no local optimizations if (element7 in 1.0 .. 3.0 != range0.contains(element7)) throw AssertionError() if (element7 !in 1.0 .. 3.0 != !range0.contains(element7)) throw AssertionError() @@ -226,10 +154,10 @@ fun testR0xE7() { fun testR0xE8() { // with possible local optimizations - if (0 in 1.0 .. 3.0 != range0.contains(0)) throw AssertionError() - if (0 !in 1.0 .. 3.0 != !range0.contains(0)) throw AssertionError() - if (!(0 in 1.0 .. 3.0) != !range0.contains(0)) throw AssertionError() - if (!(0 !in 1.0 .. 3.0) != range0.contains(0)) throw AssertionError() + if (3.toFloat() in 1.0 .. 3.0 != range0.contains(3.toFloat())) throw AssertionError() + if (3.toFloat() !in 1.0 .. 3.0 != !range0.contains(3.toFloat())) throw AssertionError() + if (!(3.toFloat() in 1.0 .. 3.0) != !range0.contains(3.toFloat())) throw AssertionError() + if (!(3.toFloat() !in 1.0 .. 3.0) != range0.contains(3.toFloat())) throw AssertionError() // no local optimizations if (element8 in 1.0 .. 3.0 != range0.contains(element8)) throw AssertionError() if (element8 !in 1.0 .. 3.0 != !range0.contains(element8)) throw AssertionError() @@ -239,10 +167,10 @@ fun testR0xE8() { fun testR0xE9() { // with possible local optimizations - if (0.toLong() in 1.0 .. 3.0 != range0.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in 1.0 .. 3.0 != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in 1.0 .. 3.0) != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in 1.0 .. 3.0) != range0.contains(0.toLong())) throw AssertionError() + if (3.toDouble() in 1.0 .. 3.0 != range0.contains(3.toDouble())) throw AssertionError() + if (3.toDouble() !in 1.0 .. 3.0 != !range0.contains(3.toDouble())) throw AssertionError() + if (!(3.toDouble() in 1.0 .. 3.0) != !range0.contains(3.toDouble())) throw AssertionError() + if (!(3.toDouble() !in 1.0 .. 3.0) != range0.contains(3.toDouble())) throw AssertionError() // no local optimizations if (element9 in 1.0 .. 3.0 != range0.contains(element9)) throw AssertionError() if (element9 !in 1.0 .. 3.0 != !range0.contains(element9)) throw AssertionError() @@ -252,10 +180,10 @@ fun testR0xE9() { fun testR0xE10() { // with possible local optimizations - if (0.toFloat() in 1.0 .. 3.0 != range0.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in 1.0 .. 3.0 != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in 1.0 .. 3.0) != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in 1.0 .. 3.0) != range0.contains(0.toFloat())) throw AssertionError() + if (4.toFloat() in 1.0 .. 3.0 != range0.contains(4.toFloat())) throw AssertionError() + if (4.toFloat() !in 1.0 .. 3.0 != !range0.contains(4.toFloat())) throw AssertionError() + if (!(4.toFloat() in 1.0 .. 3.0) != !range0.contains(4.toFloat())) throw AssertionError() + if (!(4.toFloat() !in 1.0 .. 3.0) != range0.contains(4.toFloat())) throw AssertionError() // no local optimizations if (element10 in 1.0 .. 3.0 != range0.contains(element10)) throw AssertionError() if (element10 !in 1.0 .. 3.0 != !range0.contains(element10)) throw AssertionError() @@ -265,10 +193,10 @@ fun testR0xE10() { fun testR0xE11() { // with possible local optimizations - if (0.toDouble() in 1.0 .. 3.0 != range0.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in 1.0 .. 3.0 != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in 1.0 .. 3.0) != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in 1.0 .. 3.0) != range0.contains(0.toDouble())) throw AssertionError() + if (4.toDouble() in 1.0 .. 3.0 != range0.contains(4.toDouble())) throw AssertionError() + if (4.toDouble() !in 1.0 .. 3.0 != !range0.contains(4.toDouble())) throw AssertionError() + if (!(4.toDouble() in 1.0 .. 3.0) != !range0.contains(4.toDouble())) throw AssertionError() + if (!(4.toDouble() !in 1.0 .. 3.0) != range0.contains(4.toDouble())) throw AssertionError() // no local optimizations if (element11 in 1.0 .. 3.0 != range0.contains(element11)) throw AssertionError() if (element11 !in 1.0 .. 3.0 != !range0.contains(element11)) throw AssertionError() @@ -276,324 +204,12 @@ fun testR0xE11() { if (!(element11 !in 1.0 .. 3.0) != range0.contains(element11)) throw AssertionError() } -fun testR0xE12() { - // with possible local optimizations - if (1.toByte() in 1.0 .. 3.0 != range0.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in 1.0 .. 3.0 != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in 1.0 .. 3.0) != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in 1.0 .. 3.0) != range0.contains(1.toByte())) throw AssertionError() - // no local optimizations - if (element12 in 1.0 .. 3.0 != range0.contains(element12)) throw AssertionError() - if (element12 !in 1.0 .. 3.0 != !range0.contains(element12)) throw AssertionError() - if (!(element12 in 1.0 .. 3.0) != !range0.contains(element12)) throw AssertionError() - if (!(element12 !in 1.0 .. 3.0) != range0.contains(element12)) throw AssertionError() -} - -fun testR0xE13() { - // with possible local optimizations - if (1.toShort() in 1.0 .. 3.0 != range0.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in 1.0 .. 3.0 != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in 1.0 .. 3.0) != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in 1.0 .. 3.0) != range0.contains(1.toShort())) throw AssertionError() - // no local optimizations - if (element13 in 1.0 .. 3.0 != range0.contains(element13)) throw AssertionError() - if (element13 !in 1.0 .. 3.0 != !range0.contains(element13)) throw AssertionError() - if (!(element13 in 1.0 .. 3.0) != !range0.contains(element13)) throw AssertionError() - if (!(element13 !in 1.0 .. 3.0) != range0.contains(element13)) throw AssertionError() -} - -fun testR0xE14() { - // with possible local optimizations - if (1 in 1.0 .. 3.0 != range0.contains(1)) throw AssertionError() - if (1 !in 1.0 .. 3.0 != !range0.contains(1)) throw AssertionError() - if (!(1 in 1.0 .. 3.0) != !range0.contains(1)) throw AssertionError() - if (!(1 !in 1.0 .. 3.0) != range0.contains(1)) throw AssertionError() - // no local optimizations - if (element14 in 1.0 .. 3.0 != range0.contains(element14)) throw AssertionError() - if (element14 !in 1.0 .. 3.0 != !range0.contains(element14)) throw AssertionError() - if (!(element14 in 1.0 .. 3.0) != !range0.contains(element14)) throw AssertionError() - if (!(element14 !in 1.0 .. 3.0) != range0.contains(element14)) throw AssertionError() -} - -fun testR0xE15() { - // with possible local optimizations - if (1.toLong() in 1.0 .. 3.0 != range0.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in 1.0 .. 3.0 != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in 1.0 .. 3.0) != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in 1.0 .. 3.0) != range0.contains(1.toLong())) throw AssertionError() - // no local optimizations - if (element15 in 1.0 .. 3.0 != range0.contains(element15)) throw AssertionError() - if (element15 !in 1.0 .. 3.0 != !range0.contains(element15)) throw AssertionError() - if (!(element15 in 1.0 .. 3.0) != !range0.contains(element15)) throw AssertionError() - if (!(element15 !in 1.0 .. 3.0) != range0.contains(element15)) throw AssertionError() -} - -fun testR0xE16() { - // with possible local optimizations - if (1.toFloat() in 1.0 .. 3.0 != range0.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in 1.0 .. 3.0 != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in 1.0 .. 3.0) != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in 1.0 .. 3.0) != range0.contains(1.toFloat())) throw AssertionError() - // no local optimizations - if (element16 in 1.0 .. 3.0 != range0.contains(element16)) throw AssertionError() - if (element16 !in 1.0 .. 3.0 != !range0.contains(element16)) throw AssertionError() - if (!(element16 in 1.0 .. 3.0) != !range0.contains(element16)) throw AssertionError() - if (!(element16 !in 1.0 .. 3.0) != range0.contains(element16)) throw AssertionError() -} - -fun testR0xE17() { - // with possible local optimizations - if (1.toDouble() in 1.0 .. 3.0 != range0.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in 1.0 .. 3.0 != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in 1.0 .. 3.0) != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in 1.0 .. 3.0) != range0.contains(1.toDouble())) throw AssertionError() - // no local optimizations - if (element17 in 1.0 .. 3.0 != range0.contains(element17)) throw AssertionError() - if (element17 !in 1.0 .. 3.0 != !range0.contains(element17)) throw AssertionError() - if (!(element17 in 1.0 .. 3.0) != !range0.contains(element17)) throw AssertionError() - if (!(element17 !in 1.0 .. 3.0) != range0.contains(element17)) throw AssertionError() -} - -fun testR0xE18() { - // with possible local optimizations - if (2.toByte() in 1.0 .. 3.0 != range0.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in 1.0 .. 3.0 != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in 1.0 .. 3.0) != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in 1.0 .. 3.0) != range0.contains(2.toByte())) throw AssertionError() - // no local optimizations - if (element18 in 1.0 .. 3.0 != range0.contains(element18)) throw AssertionError() - if (element18 !in 1.0 .. 3.0 != !range0.contains(element18)) throw AssertionError() - if (!(element18 in 1.0 .. 3.0) != !range0.contains(element18)) throw AssertionError() - if (!(element18 !in 1.0 .. 3.0) != range0.contains(element18)) throw AssertionError() -} - -fun testR0xE19() { - // with possible local optimizations - if (2.toShort() in 1.0 .. 3.0 != range0.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in 1.0 .. 3.0 != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in 1.0 .. 3.0) != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in 1.0 .. 3.0) != range0.contains(2.toShort())) throw AssertionError() - // no local optimizations - if (element19 in 1.0 .. 3.0 != range0.contains(element19)) throw AssertionError() - if (element19 !in 1.0 .. 3.0 != !range0.contains(element19)) throw AssertionError() - if (!(element19 in 1.0 .. 3.0) != !range0.contains(element19)) throw AssertionError() - if (!(element19 !in 1.0 .. 3.0) != range0.contains(element19)) throw AssertionError() -} - -fun testR0xE20() { - // with possible local optimizations - if (2 in 1.0 .. 3.0 != range0.contains(2)) throw AssertionError() - if (2 !in 1.0 .. 3.0 != !range0.contains(2)) throw AssertionError() - if (!(2 in 1.0 .. 3.0) != !range0.contains(2)) throw AssertionError() - if (!(2 !in 1.0 .. 3.0) != range0.contains(2)) throw AssertionError() - // no local optimizations - if (element20 in 1.0 .. 3.0 != range0.contains(element20)) throw AssertionError() - if (element20 !in 1.0 .. 3.0 != !range0.contains(element20)) throw AssertionError() - if (!(element20 in 1.0 .. 3.0) != !range0.contains(element20)) throw AssertionError() - if (!(element20 !in 1.0 .. 3.0) != range0.contains(element20)) throw AssertionError() -} - -fun testR0xE21() { - // with possible local optimizations - if (2.toLong() in 1.0 .. 3.0 != range0.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in 1.0 .. 3.0 != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in 1.0 .. 3.0) != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in 1.0 .. 3.0) != range0.contains(2.toLong())) throw AssertionError() - // no local optimizations - if (element21 in 1.0 .. 3.0 != range0.contains(element21)) throw AssertionError() - if (element21 !in 1.0 .. 3.0 != !range0.contains(element21)) throw AssertionError() - if (!(element21 in 1.0 .. 3.0) != !range0.contains(element21)) throw AssertionError() - if (!(element21 !in 1.0 .. 3.0) != range0.contains(element21)) throw AssertionError() -} - -fun testR0xE22() { - // with possible local optimizations - if (2.toFloat() in 1.0 .. 3.0 != range0.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in 1.0 .. 3.0 != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in 1.0 .. 3.0) != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in 1.0 .. 3.0) != range0.contains(2.toFloat())) throw AssertionError() - // no local optimizations - if (element22 in 1.0 .. 3.0 != range0.contains(element22)) throw AssertionError() - if (element22 !in 1.0 .. 3.0 != !range0.contains(element22)) throw AssertionError() - if (!(element22 in 1.0 .. 3.0) != !range0.contains(element22)) throw AssertionError() - if (!(element22 !in 1.0 .. 3.0) != range0.contains(element22)) throw AssertionError() -} - -fun testR0xE23() { - // with possible local optimizations - if (2.toDouble() in 1.0 .. 3.0 != range0.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in 1.0 .. 3.0 != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in 1.0 .. 3.0) != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in 1.0 .. 3.0) != range0.contains(2.toDouble())) throw AssertionError() - // no local optimizations - if (element23 in 1.0 .. 3.0 != range0.contains(element23)) throw AssertionError() - if (element23 !in 1.0 .. 3.0 != !range0.contains(element23)) throw AssertionError() - if (!(element23 in 1.0 .. 3.0) != !range0.contains(element23)) throw AssertionError() - if (!(element23 !in 1.0 .. 3.0) != range0.contains(element23)) throw AssertionError() -} - -fun testR0xE24() { - // with possible local optimizations - if (3.toByte() in 1.0 .. 3.0 != range0.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in 1.0 .. 3.0 != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in 1.0 .. 3.0) != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in 1.0 .. 3.0) != range0.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in 1.0 .. 3.0 != range0.contains(element24)) throw AssertionError() - if (element24 !in 1.0 .. 3.0 != !range0.contains(element24)) throw AssertionError() - if (!(element24 in 1.0 .. 3.0) != !range0.contains(element24)) throw AssertionError() - if (!(element24 !in 1.0 .. 3.0) != range0.contains(element24)) throw AssertionError() -} - -fun testR0xE25() { - // with possible local optimizations - if (3.toShort() in 1.0 .. 3.0 != range0.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in 1.0 .. 3.0 != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in 1.0 .. 3.0) != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in 1.0 .. 3.0) != range0.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in 1.0 .. 3.0 != range0.contains(element25)) throw AssertionError() - if (element25 !in 1.0 .. 3.0 != !range0.contains(element25)) throw AssertionError() - if (!(element25 in 1.0 .. 3.0) != !range0.contains(element25)) throw AssertionError() - if (!(element25 !in 1.0 .. 3.0) != range0.contains(element25)) throw AssertionError() -} - -fun testR0xE26() { - // with possible local optimizations - if (3 in 1.0 .. 3.0 != range0.contains(3)) throw AssertionError() - if (3 !in 1.0 .. 3.0 != !range0.contains(3)) throw AssertionError() - if (!(3 in 1.0 .. 3.0) != !range0.contains(3)) throw AssertionError() - if (!(3 !in 1.0 .. 3.0) != range0.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in 1.0 .. 3.0 != range0.contains(element26)) throw AssertionError() - if (element26 !in 1.0 .. 3.0 != !range0.contains(element26)) throw AssertionError() - if (!(element26 in 1.0 .. 3.0) != !range0.contains(element26)) throw AssertionError() - if (!(element26 !in 1.0 .. 3.0) != range0.contains(element26)) throw AssertionError() -} - -fun testR0xE27() { - // with possible local optimizations - if (3.toLong() in 1.0 .. 3.0 != range0.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in 1.0 .. 3.0 != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in 1.0 .. 3.0) != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in 1.0 .. 3.0) != range0.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in 1.0 .. 3.0 != range0.contains(element27)) throw AssertionError() - if (element27 !in 1.0 .. 3.0 != !range0.contains(element27)) throw AssertionError() - if (!(element27 in 1.0 .. 3.0) != !range0.contains(element27)) throw AssertionError() - if (!(element27 !in 1.0 .. 3.0) != range0.contains(element27)) throw AssertionError() -} - -fun testR0xE28() { - // with possible local optimizations - if (3.toFloat() in 1.0 .. 3.0 != range0.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in 1.0 .. 3.0 != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in 1.0 .. 3.0) != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in 1.0 .. 3.0) != range0.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in 1.0 .. 3.0 != range0.contains(element28)) throw AssertionError() - if (element28 !in 1.0 .. 3.0 != !range0.contains(element28)) throw AssertionError() - if (!(element28 in 1.0 .. 3.0) != !range0.contains(element28)) throw AssertionError() - if (!(element28 !in 1.0 .. 3.0) != range0.contains(element28)) throw AssertionError() -} - -fun testR0xE29() { - // with possible local optimizations - if (3.toDouble() in 1.0 .. 3.0 != range0.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in 1.0 .. 3.0 != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in 1.0 .. 3.0) != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in 1.0 .. 3.0) != range0.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in 1.0 .. 3.0 != range0.contains(element29)) throw AssertionError() - if (element29 !in 1.0 .. 3.0 != !range0.contains(element29)) throw AssertionError() - if (!(element29 in 1.0 .. 3.0) != !range0.contains(element29)) throw AssertionError() - if (!(element29 !in 1.0 .. 3.0) != range0.contains(element29)) throw AssertionError() -} - -fun testR0xE30() { - // with possible local optimizations - if (4.toByte() in 1.0 .. 3.0 != range0.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in 1.0 .. 3.0 != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in 1.0 .. 3.0) != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in 1.0 .. 3.0) != range0.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in 1.0 .. 3.0 != range0.contains(element30)) throw AssertionError() - if (element30 !in 1.0 .. 3.0 != !range0.contains(element30)) throw AssertionError() - if (!(element30 in 1.0 .. 3.0) != !range0.contains(element30)) throw AssertionError() - if (!(element30 !in 1.0 .. 3.0) != range0.contains(element30)) throw AssertionError() -} - -fun testR0xE31() { - // with possible local optimizations - if (4.toShort() in 1.0 .. 3.0 != range0.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in 1.0 .. 3.0 != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in 1.0 .. 3.0) != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in 1.0 .. 3.0) != range0.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in 1.0 .. 3.0 != range0.contains(element31)) throw AssertionError() - if (element31 !in 1.0 .. 3.0 != !range0.contains(element31)) throw AssertionError() - if (!(element31 in 1.0 .. 3.0) != !range0.contains(element31)) throw AssertionError() - if (!(element31 !in 1.0 .. 3.0) != range0.contains(element31)) throw AssertionError() -} - -fun testR0xE32() { - // with possible local optimizations - if (4 in 1.0 .. 3.0 != range0.contains(4)) throw AssertionError() - if (4 !in 1.0 .. 3.0 != !range0.contains(4)) throw AssertionError() - if (!(4 in 1.0 .. 3.0) != !range0.contains(4)) throw AssertionError() - if (!(4 !in 1.0 .. 3.0) != range0.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in 1.0 .. 3.0 != range0.contains(element32)) throw AssertionError() - if (element32 !in 1.0 .. 3.0 != !range0.contains(element32)) throw AssertionError() - if (!(element32 in 1.0 .. 3.0) != !range0.contains(element32)) throw AssertionError() - if (!(element32 !in 1.0 .. 3.0) != range0.contains(element32)) throw AssertionError() -} - -fun testR0xE33() { - // with possible local optimizations - if (4.toLong() in 1.0 .. 3.0 != range0.contains(4.toLong())) throw AssertionError() - if (4.toLong() !in 1.0 .. 3.0 != !range0.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() in 1.0 .. 3.0) != !range0.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() !in 1.0 .. 3.0) != range0.contains(4.toLong())) throw AssertionError() - // no local optimizations - if (element33 in 1.0 .. 3.0 != range0.contains(element33)) throw AssertionError() - if (element33 !in 1.0 .. 3.0 != !range0.contains(element33)) throw AssertionError() - if (!(element33 in 1.0 .. 3.0) != !range0.contains(element33)) throw AssertionError() - if (!(element33 !in 1.0 .. 3.0) != range0.contains(element33)) throw AssertionError() -} - -fun testR0xE34() { - // with possible local optimizations - if (4.toFloat() in 1.0 .. 3.0 != range0.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in 1.0 .. 3.0 != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in 1.0 .. 3.0) != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in 1.0 .. 3.0) != range0.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in 1.0 .. 3.0 != range0.contains(element34)) throw AssertionError() - if (element34 !in 1.0 .. 3.0 != !range0.contains(element34)) throw AssertionError() - if (!(element34 in 1.0 .. 3.0) != !range0.contains(element34)) throw AssertionError() - if (!(element34 !in 1.0 .. 3.0) != range0.contains(element34)) throw AssertionError() -} - -fun testR0xE35() { - // with possible local optimizations - if (4.toDouble() in 1.0 .. 3.0 != range0.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in 1.0 .. 3.0 != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in 1.0 .. 3.0) != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in 1.0 .. 3.0) != range0.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in 1.0 .. 3.0 != range0.contains(element35)) throw AssertionError() - if (element35 !in 1.0 .. 3.0 != !range0.contains(element35)) throw AssertionError() - if (!(element35 in 1.0 .. 3.0) != !range0.contains(element35)) throw AssertionError() - if (!(element35 !in 1.0 .. 3.0) != range0.contains(element35)) throw AssertionError() -} - fun testR1xE0() { // with possible local optimizations - if ((-1).toByte() in 3.0 .. 1.0 != range1.contains((-1).toByte())) throw AssertionError() - if ((-1).toByte() !in 3.0 .. 1.0 != !range1.contains((-1).toByte())) throw AssertionError() - if (!((-1).toByte() in 3.0 .. 1.0) != !range1.contains((-1).toByte())) throw AssertionError() - if (!((-1).toByte() !in 3.0 .. 1.0) != range1.contains((-1).toByte())) throw AssertionError() + if ((-1).toFloat() in 3.0 .. 1.0 != range1.contains((-1).toFloat())) throw AssertionError() + if ((-1).toFloat() !in 3.0 .. 1.0 != !range1.contains((-1).toFloat())) throw AssertionError() + if (!((-1).toFloat() in 3.0 .. 1.0) != !range1.contains((-1).toFloat())) throw AssertionError() + if (!((-1).toFloat() !in 3.0 .. 1.0) != range1.contains((-1).toFloat())) throw AssertionError() // no local optimizations if (element0 in 3.0 .. 1.0 != range1.contains(element0)) throw AssertionError() if (element0 !in 3.0 .. 1.0 != !range1.contains(element0)) throw AssertionError() @@ -603,10 +219,10 @@ fun testR1xE0() { fun testR1xE1() { // with possible local optimizations - if ((-1).toShort() in 3.0 .. 1.0 != range1.contains((-1).toShort())) throw AssertionError() - if ((-1).toShort() !in 3.0 .. 1.0 != !range1.contains((-1).toShort())) throw AssertionError() - if (!((-1).toShort() in 3.0 .. 1.0) != !range1.contains((-1).toShort())) throw AssertionError() - if (!((-1).toShort() !in 3.0 .. 1.0) != range1.contains((-1).toShort())) throw AssertionError() + if ((-1).toDouble() in 3.0 .. 1.0 != range1.contains((-1).toDouble())) throw AssertionError() + if ((-1).toDouble() !in 3.0 .. 1.0 != !range1.contains((-1).toDouble())) throw AssertionError() + if (!((-1).toDouble() in 3.0 .. 1.0) != !range1.contains((-1).toDouble())) throw AssertionError() + if (!((-1).toDouble() !in 3.0 .. 1.0) != range1.contains((-1).toDouble())) throw AssertionError() // no local optimizations if (element1 in 3.0 .. 1.0 != range1.contains(element1)) throw AssertionError() if (element1 !in 3.0 .. 1.0 != !range1.contains(element1)) throw AssertionError() @@ -616,10 +232,10 @@ fun testR1xE1() { fun testR1xE2() { // with possible local optimizations - if ((-1) in 3.0 .. 1.0 != range1.contains((-1))) throw AssertionError() - if ((-1) !in 3.0 .. 1.0 != !range1.contains((-1))) throw AssertionError() - if (!((-1) in 3.0 .. 1.0) != !range1.contains((-1))) throw AssertionError() - if (!((-1) !in 3.0 .. 1.0) != range1.contains((-1))) throw AssertionError() + if (0.toFloat() in 3.0 .. 1.0 != range1.contains(0.toFloat())) throw AssertionError() + if (0.toFloat() !in 3.0 .. 1.0 != !range1.contains(0.toFloat())) throw AssertionError() + if (!(0.toFloat() in 3.0 .. 1.0) != !range1.contains(0.toFloat())) throw AssertionError() + if (!(0.toFloat() !in 3.0 .. 1.0) != range1.contains(0.toFloat())) throw AssertionError() // no local optimizations if (element2 in 3.0 .. 1.0 != range1.contains(element2)) throw AssertionError() if (element2 !in 3.0 .. 1.0 != !range1.contains(element2)) throw AssertionError() @@ -629,10 +245,10 @@ fun testR1xE2() { fun testR1xE3() { // with possible local optimizations - if ((-1).toLong() in 3.0 .. 1.0 != range1.contains((-1).toLong())) throw AssertionError() - if ((-1).toLong() !in 3.0 .. 1.0 != !range1.contains((-1).toLong())) throw AssertionError() - if (!((-1).toLong() in 3.0 .. 1.0) != !range1.contains((-1).toLong())) throw AssertionError() - if (!((-1).toLong() !in 3.0 .. 1.0) != range1.contains((-1).toLong())) throw AssertionError() + if (0.toDouble() in 3.0 .. 1.0 != range1.contains(0.toDouble())) throw AssertionError() + if (0.toDouble() !in 3.0 .. 1.0 != !range1.contains(0.toDouble())) throw AssertionError() + if (!(0.toDouble() in 3.0 .. 1.0) != !range1.contains(0.toDouble())) throw AssertionError() + if (!(0.toDouble() !in 3.0 .. 1.0) != range1.contains(0.toDouble())) throw AssertionError() // no local optimizations if (element3 in 3.0 .. 1.0 != range1.contains(element3)) throw AssertionError() if (element3 !in 3.0 .. 1.0 != !range1.contains(element3)) throw AssertionError() @@ -642,10 +258,10 @@ fun testR1xE3() { fun testR1xE4() { // with possible local optimizations - if ((-1).toFloat() in 3.0 .. 1.0 != range1.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in 3.0 .. 1.0 != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in 3.0 .. 1.0) != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in 3.0 .. 1.0) != range1.contains((-1).toFloat())) throw AssertionError() + if (1.toFloat() in 3.0 .. 1.0 != range1.contains(1.toFloat())) throw AssertionError() + if (1.toFloat() !in 3.0 .. 1.0 != !range1.contains(1.toFloat())) throw AssertionError() + if (!(1.toFloat() in 3.0 .. 1.0) != !range1.contains(1.toFloat())) throw AssertionError() + if (!(1.toFloat() !in 3.0 .. 1.0) != range1.contains(1.toFloat())) throw AssertionError() // no local optimizations if (element4 in 3.0 .. 1.0 != range1.contains(element4)) throw AssertionError() if (element4 !in 3.0 .. 1.0 != !range1.contains(element4)) throw AssertionError() @@ -655,10 +271,10 @@ fun testR1xE4() { fun testR1xE5() { // with possible local optimizations - if ((-1).toDouble() in 3.0 .. 1.0 != range1.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in 3.0 .. 1.0 != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in 3.0 .. 1.0) != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in 3.0 .. 1.0) != range1.contains((-1).toDouble())) throw AssertionError() + if (1.toDouble() in 3.0 .. 1.0 != range1.contains(1.toDouble())) throw AssertionError() + if (1.toDouble() !in 3.0 .. 1.0 != !range1.contains(1.toDouble())) throw AssertionError() + if (!(1.toDouble() in 3.0 .. 1.0) != !range1.contains(1.toDouble())) throw AssertionError() + if (!(1.toDouble() !in 3.0 .. 1.0) != range1.contains(1.toDouble())) throw AssertionError() // no local optimizations if (element5 in 3.0 .. 1.0 != range1.contains(element5)) throw AssertionError() if (element5 !in 3.0 .. 1.0 != !range1.contains(element5)) throw AssertionError() @@ -668,10 +284,10 @@ fun testR1xE5() { fun testR1xE6() { // with possible local optimizations - if (0.toByte() in 3.0 .. 1.0 != range1.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in 3.0 .. 1.0 != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in 3.0 .. 1.0) != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in 3.0 .. 1.0) != range1.contains(0.toByte())) throw AssertionError() + if (2.toFloat() in 3.0 .. 1.0 != range1.contains(2.toFloat())) throw AssertionError() + if (2.toFloat() !in 3.0 .. 1.0 != !range1.contains(2.toFloat())) throw AssertionError() + if (!(2.toFloat() in 3.0 .. 1.0) != !range1.contains(2.toFloat())) throw AssertionError() + if (!(2.toFloat() !in 3.0 .. 1.0) != range1.contains(2.toFloat())) throw AssertionError() // no local optimizations if (element6 in 3.0 .. 1.0 != range1.contains(element6)) throw AssertionError() if (element6 !in 3.0 .. 1.0 != !range1.contains(element6)) throw AssertionError() @@ -681,10 +297,10 @@ fun testR1xE6() { fun testR1xE7() { // with possible local optimizations - if (0.toShort() in 3.0 .. 1.0 != range1.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in 3.0 .. 1.0 != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in 3.0 .. 1.0) != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in 3.0 .. 1.0) != range1.contains(0.toShort())) throw AssertionError() + if (2.toDouble() in 3.0 .. 1.0 != range1.contains(2.toDouble())) throw AssertionError() + if (2.toDouble() !in 3.0 .. 1.0 != !range1.contains(2.toDouble())) throw AssertionError() + if (!(2.toDouble() in 3.0 .. 1.0) != !range1.contains(2.toDouble())) throw AssertionError() + if (!(2.toDouble() !in 3.0 .. 1.0) != range1.contains(2.toDouble())) throw AssertionError() // no local optimizations if (element7 in 3.0 .. 1.0 != range1.contains(element7)) throw AssertionError() if (element7 !in 3.0 .. 1.0 != !range1.contains(element7)) throw AssertionError() @@ -694,10 +310,10 @@ fun testR1xE7() { fun testR1xE8() { // with possible local optimizations - if (0 in 3.0 .. 1.0 != range1.contains(0)) throw AssertionError() - if (0 !in 3.0 .. 1.0 != !range1.contains(0)) throw AssertionError() - if (!(0 in 3.0 .. 1.0) != !range1.contains(0)) throw AssertionError() - if (!(0 !in 3.0 .. 1.0) != range1.contains(0)) throw AssertionError() + if (3.toFloat() in 3.0 .. 1.0 != range1.contains(3.toFloat())) throw AssertionError() + if (3.toFloat() !in 3.0 .. 1.0 != !range1.contains(3.toFloat())) throw AssertionError() + if (!(3.toFloat() in 3.0 .. 1.0) != !range1.contains(3.toFloat())) throw AssertionError() + if (!(3.toFloat() !in 3.0 .. 1.0) != range1.contains(3.toFloat())) throw AssertionError() // no local optimizations if (element8 in 3.0 .. 1.0 != range1.contains(element8)) throw AssertionError() if (element8 !in 3.0 .. 1.0 != !range1.contains(element8)) throw AssertionError() @@ -707,10 +323,10 @@ fun testR1xE8() { fun testR1xE9() { // with possible local optimizations - if (0.toLong() in 3.0 .. 1.0 != range1.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in 3.0 .. 1.0 != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in 3.0 .. 1.0) != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in 3.0 .. 1.0) != range1.contains(0.toLong())) throw AssertionError() + if (3.toDouble() in 3.0 .. 1.0 != range1.contains(3.toDouble())) throw AssertionError() + if (3.toDouble() !in 3.0 .. 1.0 != !range1.contains(3.toDouble())) throw AssertionError() + if (!(3.toDouble() in 3.0 .. 1.0) != !range1.contains(3.toDouble())) throw AssertionError() + if (!(3.toDouble() !in 3.0 .. 1.0) != range1.contains(3.toDouble())) throw AssertionError() // no local optimizations if (element9 in 3.0 .. 1.0 != range1.contains(element9)) throw AssertionError() if (element9 !in 3.0 .. 1.0 != !range1.contains(element9)) throw AssertionError() @@ -720,10 +336,10 @@ fun testR1xE9() { fun testR1xE10() { // with possible local optimizations - if (0.toFloat() in 3.0 .. 1.0 != range1.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in 3.0 .. 1.0 != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in 3.0 .. 1.0) != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in 3.0 .. 1.0) != range1.contains(0.toFloat())) throw AssertionError() + if (4.toFloat() in 3.0 .. 1.0 != range1.contains(4.toFloat())) throw AssertionError() + if (4.toFloat() !in 3.0 .. 1.0 != !range1.contains(4.toFloat())) throw AssertionError() + if (!(4.toFloat() in 3.0 .. 1.0) != !range1.contains(4.toFloat())) throw AssertionError() + if (!(4.toFloat() !in 3.0 .. 1.0) != range1.contains(4.toFloat())) throw AssertionError() // no local optimizations if (element10 in 3.0 .. 1.0 != range1.contains(element10)) throw AssertionError() if (element10 !in 3.0 .. 1.0 != !range1.contains(element10)) throw AssertionError() @@ -733,10 +349,10 @@ fun testR1xE10() { fun testR1xE11() { // with possible local optimizations - if (0.toDouble() in 3.0 .. 1.0 != range1.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in 3.0 .. 1.0 != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in 3.0 .. 1.0) != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in 3.0 .. 1.0) != range1.contains(0.toDouble())) throw AssertionError() + if (4.toDouble() in 3.0 .. 1.0 != range1.contains(4.toDouble())) throw AssertionError() + if (4.toDouble() !in 3.0 .. 1.0 != !range1.contains(4.toDouble())) throw AssertionError() + if (!(4.toDouble() in 3.0 .. 1.0) != !range1.contains(4.toDouble())) throw AssertionError() + if (!(4.toDouble() !in 3.0 .. 1.0) != range1.contains(4.toDouble())) throw AssertionError() // no local optimizations if (element11 in 3.0 .. 1.0 != range1.contains(element11)) throw AssertionError() if (element11 !in 3.0 .. 1.0 != !range1.contains(element11)) throw AssertionError() @@ -744,316 +360,4 @@ fun testR1xE11() { if (!(element11 !in 3.0 .. 1.0) != range1.contains(element11)) throw AssertionError() } -fun testR1xE12() { - // with possible local optimizations - if (1.toByte() in 3.0 .. 1.0 != range1.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in 3.0 .. 1.0 != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in 3.0 .. 1.0) != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in 3.0 .. 1.0) != range1.contains(1.toByte())) throw AssertionError() - // no local optimizations - if (element12 in 3.0 .. 1.0 != range1.contains(element12)) throw AssertionError() - if (element12 !in 3.0 .. 1.0 != !range1.contains(element12)) throw AssertionError() - if (!(element12 in 3.0 .. 1.0) != !range1.contains(element12)) throw AssertionError() - if (!(element12 !in 3.0 .. 1.0) != range1.contains(element12)) throw AssertionError() -} - -fun testR1xE13() { - // with possible local optimizations - if (1.toShort() in 3.0 .. 1.0 != range1.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in 3.0 .. 1.0 != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in 3.0 .. 1.0) != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in 3.0 .. 1.0) != range1.contains(1.toShort())) throw AssertionError() - // no local optimizations - if (element13 in 3.0 .. 1.0 != range1.contains(element13)) throw AssertionError() - if (element13 !in 3.0 .. 1.0 != !range1.contains(element13)) throw AssertionError() - if (!(element13 in 3.0 .. 1.0) != !range1.contains(element13)) throw AssertionError() - if (!(element13 !in 3.0 .. 1.0) != range1.contains(element13)) throw AssertionError() -} - -fun testR1xE14() { - // with possible local optimizations - if (1 in 3.0 .. 1.0 != range1.contains(1)) throw AssertionError() - if (1 !in 3.0 .. 1.0 != !range1.contains(1)) throw AssertionError() - if (!(1 in 3.0 .. 1.0) != !range1.contains(1)) throw AssertionError() - if (!(1 !in 3.0 .. 1.0) != range1.contains(1)) throw AssertionError() - // no local optimizations - if (element14 in 3.0 .. 1.0 != range1.contains(element14)) throw AssertionError() - if (element14 !in 3.0 .. 1.0 != !range1.contains(element14)) throw AssertionError() - if (!(element14 in 3.0 .. 1.0) != !range1.contains(element14)) throw AssertionError() - if (!(element14 !in 3.0 .. 1.0) != range1.contains(element14)) throw AssertionError() -} - -fun testR1xE15() { - // with possible local optimizations - if (1.toLong() in 3.0 .. 1.0 != range1.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in 3.0 .. 1.0 != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in 3.0 .. 1.0) != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in 3.0 .. 1.0) != range1.contains(1.toLong())) throw AssertionError() - // no local optimizations - if (element15 in 3.0 .. 1.0 != range1.contains(element15)) throw AssertionError() - if (element15 !in 3.0 .. 1.0 != !range1.contains(element15)) throw AssertionError() - if (!(element15 in 3.0 .. 1.0) != !range1.contains(element15)) throw AssertionError() - if (!(element15 !in 3.0 .. 1.0) != range1.contains(element15)) throw AssertionError() -} - -fun testR1xE16() { - // with possible local optimizations - if (1.toFloat() in 3.0 .. 1.0 != range1.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in 3.0 .. 1.0 != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in 3.0 .. 1.0) != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in 3.0 .. 1.0) != range1.contains(1.toFloat())) throw AssertionError() - // no local optimizations - if (element16 in 3.0 .. 1.0 != range1.contains(element16)) throw AssertionError() - if (element16 !in 3.0 .. 1.0 != !range1.contains(element16)) throw AssertionError() - if (!(element16 in 3.0 .. 1.0) != !range1.contains(element16)) throw AssertionError() - if (!(element16 !in 3.0 .. 1.0) != range1.contains(element16)) throw AssertionError() -} - -fun testR1xE17() { - // with possible local optimizations - if (1.toDouble() in 3.0 .. 1.0 != range1.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in 3.0 .. 1.0 != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in 3.0 .. 1.0) != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in 3.0 .. 1.0) != range1.contains(1.toDouble())) throw AssertionError() - // no local optimizations - if (element17 in 3.0 .. 1.0 != range1.contains(element17)) throw AssertionError() - if (element17 !in 3.0 .. 1.0 != !range1.contains(element17)) throw AssertionError() - if (!(element17 in 3.0 .. 1.0) != !range1.contains(element17)) throw AssertionError() - if (!(element17 !in 3.0 .. 1.0) != range1.contains(element17)) throw AssertionError() -} - -fun testR1xE18() { - // with possible local optimizations - if (2.toByte() in 3.0 .. 1.0 != range1.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in 3.0 .. 1.0 != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in 3.0 .. 1.0) != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in 3.0 .. 1.0) != range1.contains(2.toByte())) throw AssertionError() - // no local optimizations - if (element18 in 3.0 .. 1.0 != range1.contains(element18)) throw AssertionError() - if (element18 !in 3.0 .. 1.0 != !range1.contains(element18)) throw AssertionError() - if (!(element18 in 3.0 .. 1.0) != !range1.contains(element18)) throw AssertionError() - if (!(element18 !in 3.0 .. 1.0) != range1.contains(element18)) throw AssertionError() -} - -fun testR1xE19() { - // with possible local optimizations - if (2.toShort() in 3.0 .. 1.0 != range1.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in 3.0 .. 1.0 != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in 3.0 .. 1.0) != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in 3.0 .. 1.0) != range1.contains(2.toShort())) throw AssertionError() - // no local optimizations - if (element19 in 3.0 .. 1.0 != range1.contains(element19)) throw AssertionError() - if (element19 !in 3.0 .. 1.0 != !range1.contains(element19)) throw AssertionError() - if (!(element19 in 3.0 .. 1.0) != !range1.contains(element19)) throw AssertionError() - if (!(element19 !in 3.0 .. 1.0) != range1.contains(element19)) throw AssertionError() -} - -fun testR1xE20() { - // with possible local optimizations - if (2 in 3.0 .. 1.0 != range1.contains(2)) throw AssertionError() - if (2 !in 3.0 .. 1.0 != !range1.contains(2)) throw AssertionError() - if (!(2 in 3.0 .. 1.0) != !range1.contains(2)) throw AssertionError() - if (!(2 !in 3.0 .. 1.0) != range1.contains(2)) throw AssertionError() - // no local optimizations - if (element20 in 3.0 .. 1.0 != range1.contains(element20)) throw AssertionError() - if (element20 !in 3.0 .. 1.0 != !range1.contains(element20)) throw AssertionError() - if (!(element20 in 3.0 .. 1.0) != !range1.contains(element20)) throw AssertionError() - if (!(element20 !in 3.0 .. 1.0) != range1.contains(element20)) throw AssertionError() -} - -fun testR1xE21() { - // with possible local optimizations - if (2.toLong() in 3.0 .. 1.0 != range1.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in 3.0 .. 1.0 != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in 3.0 .. 1.0) != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in 3.0 .. 1.0) != range1.contains(2.toLong())) throw AssertionError() - // no local optimizations - if (element21 in 3.0 .. 1.0 != range1.contains(element21)) throw AssertionError() - if (element21 !in 3.0 .. 1.0 != !range1.contains(element21)) throw AssertionError() - if (!(element21 in 3.0 .. 1.0) != !range1.contains(element21)) throw AssertionError() - if (!(element21 !in 3.0 .. 1.0) != range1.contains(element21)) throw AssertionError() -} - -fun testR1xE22() { - // with possible local optimizations - if (2.toFloat() in 3.0 .. 1.0 != range1.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in 3.0 .. 1.0 != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in 3.0 .. 1.0) != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in 3.0 .. 1.0) != range1.contains(2.toFloat())) throw AssertionError() - // no local optimizations - if (element22 in 3.0 .. 1.0 != range1.contains(element22)) throw AssertionError() - if (element22 !in 3.0 .. 1.0 != !range1.contains(element22)) throw AssertionError() - if (!(element22 in 3.0 .. 1.0) != !range1.contains(element22)) throw AssertionError() - if (!(element22 !in 3.0 .. 1.0) != range1.contains(element22)) throw AssertionError() -} - -fun testR1xE23() { - // with possible local optimizations - if (2.toDouble() in 3.0 .. 1.0 != range1.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in 3.0 .. 1.0 != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in 3.0 .. 1.0) != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in 3.0 .. 1.0) != range1.contains(2.toDouble())) throw AssertionError() - // no local optimizations - if (element23 in 3.0 .. 1.0 != range1.contains(element23)) throw AssertionError() - if (element23 !in 3.0 .. 1.0 != !range1.contains(element23)) throw AssertionError() - if (!(element23 in 3.0 .. 1.0) != !range1.contains(element23)) throw AssertionError() - if (!(element23 !in 3.0 .. 1.0) != range1.contains(element23)) throw AssertionError() -} - -fun testR1xE24() { - // with possible local optimizations - if (3.toByte() in 3.0 .. 1.0 != range1.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in 3.0 .. 1.0 != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in 3.0 .. 1.0) != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in 3.0 .. 1.0) != range1.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in 3.0 .. 1.0 != range1.contains(element24)) throw AssertionError() - if (element24 !in 3.0 .. 1.0 != !range1.contains(element24)) throw AssertionError() - if (!(element24 in 3.0 .. 1.0) != !range1.contains(element24)) throw AssertionError() - if (!(element24 !in 3.0 .. 1.0) != range1.contains(element24)) throw AssertionError() -} - -fun testR1xE25() { - // with possible local optimizations - if (3.toShort() in 3.0 .. 1.0 != range1.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in 3.0 .. 1.0 != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in 3.0 .. 1.0) != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in 3.0 .. 1.0) != range1.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in 3.0 .. 1.0 != range1.contains(element25)) throw AssertionError() - if (element25 !in 3.0 .. 1.0 != !range1.contains(element25)) throw AssertionError() - if (!(element25 in 3.0 .. 1.0) != !range1.contains(element25)) throw AssertionError() - if (!(element25 !in 3.0 .. 1.0) != range1.contains(element25)) throw AssertionError() -} - -fun testR1xE26() { - // with possible local optimizations - if (3 in 3.0 .. 1.0 != range1.contains(3)) throw AssertionError() - if (3 !in 3.0 .. 1.0 != !range1.contains(3)) throw AssertionError() - if (!(3 in 3.0 .. 1.0) != !range1.contains(3)) throw AssertionError() - if (!(3 !in 3.0 .. 1.0) != range1.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in 3.0 .. 1.0 != range1.contains(element26)) throw AssertionError() - if (element26 !in 3.0 .. 1.0 != !range1.contains(element26)) throw AssertionError() - if (!(element26 in 3.0 .. 1.0) != !range1.contains(element26)) throw AssertionError() - if (!(element26 !in 3.0 .. 1.0) != range1.contains(element26)) throw AssertionError() -} - -fun testR1xE27() { - // with possible local optimizations - if (3.toLong() in 3.0 .. 1.0 != range1.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in 3.0 .. 1.0 != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in 3.0 .. 1.0) != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in 3.0 .. 1.0) != range1.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in 3.0 .. 1.0 != range1.contains(element27)) throw AssertionError() - if (element27 !in 3.0 .. 1.0 != !range1.contains(element27)) throw AssertionError() - if (!(element27 in 3.0 .. 1.0) != !range1.contains(element27)) throw AssertionError() - if (!(element27 !in 3.0 .. 1.0) != range1.contains(element27)) throw AssertionError() -} - -fun testR1xE28() { - // with possible local optimizations - if (3.toFloat() in 3.0 .. 1.0 != range1.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in 3.0 .. 1.0 != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in 3.0 .. 1.0) != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in 3.0 .. 1.0) != range1.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in 3.0 .. 1.0 != range1.contains(element28)) throw AssertionError() - if (element28 !in 3.0 .. 1.0 != !range1.contains(element28)) throw AssertionError() - if (!(element28 in 3.0 .. 1.0) != !range1.contains(element28)) throw AssertionError() - if (!(element28 !in 3.0 .. 1.0) != range1.contains(element28)) throw AssertionError() -} - -fun testR1xE29() { - // with possible local optimizations - if (3.toDouble() in 3.0 .. 1.0 != range1.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in 3.0 .. 1.0 != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in 3.0 .. 1.0) != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in 3.0 .. 1.0) != range1.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in 3.0 .. 1.0 != range1.contains(element29)) throw AssertionError() - if (element29 !in 3.0 .. 1.0 != !range1.contains(element29)) throw AssertionError() - if (!(element29 in 3.0 .. 1.0) != !range1.contains(element29)) throw AssertionError() - if (!(element29 !in 3.0 .. 1.0) != range1.contains(element29)) throw AssertionError() -} - -fun testR1xE30() { - // with possible local optimizations - if (4.toByte() in 3.0 .. 1.0 != range1.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in 3.0 .. 1.0 != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in 3.0 .. 1.0) != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in 3.0 .. 1.0) != range1.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in 3.0 .. 1.0 != range1.contains(element30)) throw AssertionError() - if (element30 !in 3.0 .. 1.0 != !range1.contains(element30)) throw AssertionError() - if (!(element30 in 3.0 .. 1.0) != !range1.contains(element30)) throw AssertionError() - if (!(element30 !in 3.0 .. 1.0) != range1.contains(element30)) throw AssertionError() -} - -fun testR1xE31() { - // with possible local optimizations - if (4.toShort() in 3.0 .. 1.0 != range1.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in 3.0 .. 1.0 != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in 3.0 .. 1.0) != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in 3.0 .. 1.0) != range1.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in 3.0 .. 1.0 != range1.contains(element31)) throw AssertionError() - if (element31 !in 3.0 .. 1.0 != !range1.contains(element31)) throw AssertionError() - if (!(element31 in 3.0 .. 1.0) != !range1.contains(element31)) throw AssertionError() - if (!(element31 !in 3.0 .. 1.0) != range1.contains(element31)) throw AssertionError() -} - -fun testR1xE32() { - // with possible local optimizations - if (4 in 3.0 .. 1.0 != range1.contains(4)) throw AssertionError() - if (4 !in 3.0 .. 1.0 != !range1.contains(4)) throw AssertionError() - if (!(4 in 3.0 .. 1.0) != !range1.contains(4)) throw AssertionError() - if (!(4 !in 3.0 .. 1.0) != range1.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in 3.0 .. 1.0 != range1.contains(element32)) throw AssertionError() - if (element32 !in 3.0 .. 1.0 != !range1.contains(element32)) throw AssertionError() - if (!(element32 in 3.0 .. 1.0) != !range1.contains(element32)) throw AssertionError() - if (!(element32 !in 3.0 .. 1.0) != range1.contains(element32)) throw AssertionError() -} - -fun testR1xE33() { - // with possible local optimizations - if (4.toLong() in 3.0 .. 1.0 != range1.contains(4.toLong())) throw AssertionError() - if (4.toLong() !in 3.0 .. 1.0 != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() in 3.0 .. 1.0) != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() !in 3.0 .. 1.0) != range1.contains(4.toLong())) throw AssertionError() - // no local optimizations - if (element33 in 3.0 .. 1.0 != range1.contains(element33)) throw AssertionError() - if (element33 !in 3.0 .. 1.0 != !range1.contains(element33)) throw AssertionError() - if (!(element33 in 3.0 .. 1.0) != !range1.contains(element33)) throw AssertionError() - if (!(element33 !in 3.0 .. 1.0) != range1.contains(element33)) throw AssertionError() -} - -fun testR1xE34() { - // with possible local optimizations - if (4.toFloat() in 3.0 .. 1.0 != range1.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in 3.0 .. 1.0 != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in 3.0 .. 1.0) != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in 3.0 .. 1.0) != range1.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in 3.0 .. 1.0 != range1.contains(element34)) throw AssertionError() - if (element34 !in 3.0 .. 1.0 != !range1.contains(element34)) throw AssertionError() - if (!(element34 in 3.0 .. 1.0) != !range1.contains(element34)) throw AssertionError() - if (!(element34 !in 3.0 .. 1.0) != range1.contains(element34)) throw AssertionError() -} - -fun testR1xE35() { - // with possible local optimizations - if (4.toDouble() in 3.0 .. 1.0 != range1.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in 3.0 .. 1.0 != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in 3.0 .. 1.0) != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in 3.0 .. 1.0) != range1.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in 3.0 .. 1.0 != range1.contains(element35)) throw AssertionError() - if (element35 !in 3.0 .. 1.0 != !range1.contains(element35)) throw AssertionError() - if (!(element35 in 3.0 .. 1.0) != !range1.contains(element35)) throw AssertionError() - if (!(element35 !in 3.0 .. 1.0) != range1.contains(element35)) throw AssertionError() -} - diff --git a/compiler/testData/codegen/box/ranges/contains/generated/floatRangeLiteral.kt b/compiler/testData/codegen/box/ranges/contains/generated/floatRangeLiteral.kt index 2380c7987ee..5fb5006a118 100644 --- a/compiler/testData/codegen/box/ranges/contains/generated/floatRangeLiteral.kt +++ b/compiler/testData/codegen/box/ranges/contains/generated/floatRangeLiteral.kt @@ -7,42 +7,18 @@ val range0 = 1.0F .. 3.0F val range1 = 3.0F .. 1.0F -val element0 = (-1).toByte() -val element1 = (-1).toShort() -val element2 = (-1) -val element3 = (-1).toLong() -val element4 = (-1).toFloat() -val element5 = (-1).toDouble() -val element6 = 0.toByte() -val element7 = 0.toShort() -val element8 = 0 -val element9 = 0.toLong() -val element10 = 0.toFloat() -val element11 = 0.toDouble() -val element12 = 1.toByte() -val element13 = 1.toShort() -val element14 = 1 -val element15 = 1.toLong() -val element16 = 1.toFloat() -val element17 = 1.toDouble() -val element18 = 2.toByte() -val element19 = 2.toShort() -val element20 = 2 -val element21 = 2.toLong() -val element22 = 2.toFloat() -val element23 = 2.toDouble() -val element24 = 3.toByte() -val element25 = 3.toShort() -val element26 = 3 -val element27 = 3.toLong() -val element28 = 3.toFloat() -val element29 = 3.toDouble() -val element30 = 4.toByte() -val element31 = 4.toShort() -val element32 = 4 -val element33 = 4.toLong() -val element34 = 4.toFloat() -val element35 = 4.toDouble() +val element0 = (-1).toFloat() +val element1 = (-1).toDouble() +val element2 = 0.toFloat() +val element3 = 0.toDouble() +val element4 = 1.toFloat() +val element5 = 1.toDouble() +val element6 = 2.toFloat() +val element7 = 2.toDouble() +val element8 = 3.toFloat() +val element9 = 3.toDouble() +val element10 = 4.toFloat() +val element11 = 4.toDouble() fun box(): String { testR0xE0() @@ -57,30 +33,6 @@ fun box(): String { testR0xE9() testR0xE10() testR0xE11() - testR0xE12() - testR0xE13() - testR0xE14() - testR0xE15() - testR0xE16() - testR0xE17() - testR0xE18() - testR0xE19() - testR0xE20() - testR0xE21() - testR0xE22() - testR0xE23() - testR0xE24() - testR0xE25() - testR0xE26() - testR0xE27() - testR0xE28() - testR0xE29() - testR0xE30() - testR0xE31() - testR0xE32() - testR0xE33() - testR0xE34() - testR0xE35() testR1xE0() testR1xE1() testR1xE2() @@ -93,39 +45,15 @@ fun box(): String { testR1xE9() testR1xE10() testR1xE11() - testR1xE12() - testR1xE13() - testR1xE14() - testR1xE15() - testR1xE16() - testR1xE17() - testR1xE18() - testR1xE19() - testR1xE20() - testR1xE21() - testR1xE22() - testR1xE23() - testR1xE24() - testR1xE25() - testR1xE26() - testR1xE27() - testR1xE28() - testR1xE29() - testR1xE30() - testR1xE31() - testR1xE32() - testR1xE33() - testR1xE34() - testR1xE35() return "OK" } fun testR0xE0() { // with possible local optimizations - if ((-1).toByte() in 1.0F .. 3.0F != range0.contains((-1).toByte())) throw AssertionError() - if ((-1).toByte() !in 1.0F .. 3.0F != !range0.contains((-1).toByte())) throw AssertionError() - if (!((-1).toByte() in 1.0F .. 3.0F) != !range0.contains((-1).toByte())) throw AssertionError() - if (!((-1).toByte() !in 1.0F .. 3.0F) != range0.contains((-1).toByte())) throw AssertionError() + if ((-1).toFloat() in 1.0F .. 3.0F != range0.contains((-1).toFloat())) throw AssertionError() + if ((-1).toFloat() !in 1.0F .. 3.0F != !range0.contains((-1).toFloat())) throw AssertionError() + if (!((-1).toFloat() in 1.0F .. 3.0F) != !range0.contains((-1).toFloat())) throw AssertionError() + if (!((-1).toFloat() !in 1.0F .. 3.0F) != range0.contains((-1).toFloat())) throw AssertionError() // no local optimizations if (element0 in 1.0F .. 3.0F != range0.contains(element0)) throw AssertionError() if (element0 !in 1.0F .. 3.0F != !range0.contains(element0)) throw AssertionError() @@ -135,10 +63,10 @@ fun testR0xE0() { fun testR0xE1() { // with possible local optimizations - if ((-1).toShort() in 1.0F .. 3.0F != range0.contains((-1).toShort())) throw AssertionError() - if ((-1).toShort() !in 1.0F .. 3.0F != !range0.contains((-1).toShort())) throw AssertionError() - if (!((-1).toShort() in 1.0F .. 3.0F) != !range0.contains((-1).toShort())) throw AssertionError() - if (!((-1).toShort() !in 1.0F .. 3.0F) != range0.contains((-1).toShort())) throw AssertionError() + if ((-1).toDouble() in 1.0F .. 3.0F != range0.contains((-1).toDouble())) throw AssertionError() + if ((-1).toDouble() !in 1.0F .. 3.0F != !range0.contains((-1).toDouble())) throw AssertionError() + if (!((-1).toDouble() in 1.0F .. 3.0F) != !range0.contains((-1).toDouble())) throw AssertionError() + if (!((-1).toDouble() !in 1.0F .. 3.0F) != range0.contains((-1).toDouble())) throw AssertionError() // no local optimizations if (element1 in 1.0F .. 3.0F != range0.contains(element1)) throw AssertionError() if (element1 !in 1.0F .. 3.0F != !range0.contains(element1)) throw AssertionError() @@ -148,10 +76,10 @@ fun testR0xE1() { fun testR0xE2() { // with possible local optimizations - if ((-1) in 1.0F .. 3.0F != range0.contains((-1))) throw AssertionError() - if ((-1) !in 1.0F .. 3.0F != !range0.contains((-1))) throw AssertionError() - if (!((-1) in 1.0F .. 3.0F) != !range0.contains((-1))) throw AssertionError() - if (!((-1) !in 1.0F .. 3.0F) != range0.contains((-1))) throw AssertionError() + if (0.toFloat() in 1.0F .. 3.0F != range0.contains(0.toFloat())) throw AssertionError() + if (0.toFloat() !in 1.0F .. 3.0F != !range0.contains(0.toFloat())) throw AssertionError() + if (!(0.toFloat() in 1.0F .. 3.0F) != !range0.contains(0.toFloat())) throw AssertionError() + if (!(0.toFloat() !in 1.0F .. 3.0F) != range0.contains(0.toFloat())) throw AssertionError() // no local optimizations if (element2 in 1.0F .. 3.0F != range0.contains(element2)) throw AssertionError() if (element2 !in 1.0F .. 3.0F != !range0.contains(element2)) throw AssertionError() @@ -161,10 +89,10 @@ fun testR0xE2() { fun testR0xE3() { // with possible local optimizations - if ((-1).toLong() in 1.0F .. 3.0F != range0.contains((-1).toLong())) throw AssertionError() - if ((-1).toLong() !in 1.0F .. 3.0F != !range0.contains((-1).toLong())) throw AssertionError() - if (!((-1).toLong() in 1.0F .. 3.0F) != !range0.contains((-1).toLong())) throw AssertionError() - if (!((-1).toLong() !in 1.0F .. 3.0F) != range0.contains((-1).toLong())) throw AssertionError() + if (0.toDouble() in 1.0F .. 3.0F != range0.contains(0.toDouble())) throw AssertionError() + if (0.toDouble() !in 1.0F .. 3.0F != !range0.contains(0.toDouble())) throw AssertionError() + if (!(0.toDouble() in 1.0F .. 3.0F) != !range0.contains(0.toDouble())) throw AssertionError() + if (!(0.toDouble() !in 1.0F .. 3.0F) != range0.contains(0.toDouble())) throw AssertionError() // no local optimizations if (element3 in 1.0F .. 3.0F != range0.contains(element3)) throw AssertionError() if (element3 !in 1.0F .. 3.0F != !range0.contains(element3)) throw AssertionError() @@ -174,10 +102,10 @@ fun testR0xE3() { fun testR0xE4() { // with possible local optimizations - if ((-1).toFloat() in 1.0F .. 3.0F != range0.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in 1.0F .. 3.0F != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in 1.0F .. 3.0F) != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in 1.0F .. 3.0F) != range0.contains((-1).toFloat())) throw AssertionError() + if (1.toFloat() in 1.0F .. 3.0F != range0.contains(1.toFloat())) throw AssertionError() + if (1.toFloat() !in 1.0F .. 3.0F != !range0.contains(1.toFloat())) throw AssertionError() + if (!(1.toFloat() in 1.0F .. 3.0F) != !range0.contains(1.toFloat())) throw AssertionError() + if (!(1.toFloat() !in 1.0F .. 3.0F) != range0.contains(1.toFloat())) throw AssertionError() // no local optimizations if (element4 in 1.0F .. 3.0F != range0.contains(element4)) throw AssertionError() if (element4 !in 1.0F .. 3.0F != !range0.contains(element4)) throw AssertionError() @@ -187,10 +115,10 @@ fun testR0xE4() { fun testR0xE5() { // with possible local optimizations - if ((-1).toDouble() in 1.0F .. 3.0F != range0.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in 1.0F .. 3.0F != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in 1.0F .. 3.0F) != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in 1.0F .. 3.0F) != range0.contains((-1).toDouble())) throw AssertionError() + if (1.toDouble() in 1.0F .. 3.0F != range0.contains(1.toDouble())) throw AssertionError() + if (1.toDouble() !in 1.0F .. 3.0F != !range0.contains(1.toDouble())) throw AssertionError() + if (!(1.toDouble() in 1.0F .. 3.0F) != !range0.contains(1.toDouble())) throw AssertionError() + if (!(1.toDouble() !in 1.0F .. 3.0F) != range0.contains(1.toDouble())) throw AssertionError() // no local optimizations if (element5 in 1.0F .. 3.0F != range0.contains(element5)) throw AssertionError() if (element5 !in 1.0F .. 3.0F != !range0.contains(element5)) throw AssertionError() @@ -200,10 +128,10 @@ fun testR0xE5() { fun testR0xE6() { // with possible local optimizations - if (0.toByte() in 1.0F .. 3.0F != range0.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in 1.0F .. 3.0F != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in 1.0F .. 3.0F) != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in 1.0F .. 3.0F) != range0.contains(0.toByte())) throw AssertionError() + if (2.toFloat() in 1.0F .. 3.0F != range0.contains(2.toFloat())) throw AssertionError() + if (2.toFloat() !in 1.0F .. 3.0F != !range0.contains(2.toFloat())) throw AssertionError() + if (!(2.toFloat() in 1.0F .. 3.0F) != !range0.contains(2.toFloat())) throw AssertionError() + if (!(2.toFloat() !in 1.0F .. 3.0F) != range0.contains(2.toFloat())) throw AssertionError() // no local optimizations if (element6 in 1.0F .. 3.0F != range0.contains(element6)) throw AssertionError() if (element6 !in 1.0F .. 3.0F != !range0.contains(element6)) throw AssertionError() @@ -213,10 +141,10 @@ fun testR0xE6() { fun testR0xE7() { // with possible local optimizations - if (0.toShort() in 1.0F .. 3.0F != range0.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in 1.0F .. 3.0F != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in 1.0F .. 3.0F) != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in 1.0F .. 3.0F) != range0.contains(0.toShort())) throw AssertionError() + if (2.toDouble() in 1.0F .. 3.0F != range0.contains(2.toDouble())) throw AssertionError() + if (2.toDouble() !in 1.0F .. 3.0F != !range0.contains(2.toDouble())) throw AssertionError() + if (!(2.toDouble() in 1.0F .. 3.0F) != !range0.contains(2.toDouble())) throw AssertionError() + if (!(2.toDouble() !in 1.0F .. 3.0F) != range0.contains(2.toDouble())) throw AssertionError() // no local optimizations if (element7 in 1.0F .. 3.0F != range0.contains(element7)) throw AssertionError() if (element7 !in 1.0F .. 3.0F != !range0.contains(element7)) throw AssertionError() @@ -226,10 +154,10 @@ fun testR0xE7() { fun testR0xE8() { // with possible local optimizations - if (0 in 1.0F .. 3.0F != range0.contains(0)) throw AssertionError() - if (0 !in 1.0F .. 3.0F != !range0.contains(0)) throw AssertionError() - if (!(0 in 1.0F .. 3.0F) != !range0.contains(0)) throw AssertionError() - if (!(0 !in 1.0F .. 3.0F) != range0.contains(0)) throw AssertionError() + if (3.toFloat() in 1.0F .. 3.0F != range0.contains(3.toFloat())) throw AssertionError() + if (3.toFloat() !in 1.0F .. 3.0F != !range0.contains(3.toFloat())) throw AssertionError() + if (!(3.toFloat() in 1.0F .. 3.0F) != !range0.contains(3.toFloat())) throw AssertionError() + if (!(3.toFloat() !in 1.0F .. 3.0F) != range0.contains(3.toFloat())) throw AssertionError() // no local optimizations if (element8 in 1.0F .. 3.0F != range0.contains(element8)) throw AssertionError() if (element8 !in 1.0F .. 3.0F != !range0.contains(element8)) throw AssertionError() @@ -239,10 +167,10 @@ fun testR0xE8() { fun testR0xE9() { // with possible local optimizations - if (0.toLong() in 1.0F .. 3.0F != range0.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in 1.0F .. 3.0F != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in 1.0F .. 3.0F) != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in 1.0F .. 3.0F) != range0.contains(0.toLong())) throw AssertionError() + if (3.toDouble() in 1.0F .. 3.0F != range0.contains(3.toDouble())) throw AssertionError() + if (3.toDouble() !in 1.0F .. 3.0F != !range0.contains(3.toDouble())) throw AssertionError() + if (!(3.toDouble() in 1.0F .. 3.0F) != !range0.contains(3.toDouble())) throw AssertionError() + if (!(3.toDouble() !in 1.0F .. 3.0F) != range0.contains(3.toDouble())) throw AssertionError() // no local optimizations if (element9 in 1.0F .. 3.0F != range0.contains(element9)) throw AssertionError() if (element9 !in 1.0F .. 3.0F != !range0.contains(element9)) throw AssertionError() @@ -252,10 +180,10 @@ fun testR0xE9() { fun testR0xE10() { // with possible local optimizations - if (0.toFloat() in 1.0F .. 3.0F != range0.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in 1.0F .. 3.0F != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in 1.0F .. 3.0F) != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in 1.0F .. 3.0F) != range0.contains(0.toFloat())) throw AssertionError() + if (4.toFloat() in 1.0F .. 3.0F != range0.contains(4.toFloat())) throw AssertionError() + if (4.toFloat() !in 1.0F .. 3.0F != !range0.contains(4.toFloat())) throw AssertionError() + if (!(4.toFloat() in 1.0F .. 3.0F) != !range0.contains(4.toFloat())) throw AssertionError() + if (!(4.toFloat() !in 1.0F .. 3.0F) != range0.contains(4.toFloat())) throw AssertionError() // no local optimizations if (element10 in 1.0F .. 3.0F != range0.contains(element10)) throw AssertionError() if (element10 !in 1.0F .. 3.0F != !range0.contains(element10)) throw AssertionError() @@ -265,10 +193,10 @@ fun testR0xE10() { fun testR0xE11() { // with possible local optimizations - if (0.toDouble() in 1.0F .. 3.0F != range0.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in 1.0F .. 3.0F != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in 1.0F .. 3.0F) != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in 1.0F .. 3.0F) != range0.contains(0.toDouble())) throw AssertionError() + if (4.toDouble() in 1.0F .. 3.0F != range0.contains(4.toDouble())) throw AssertionError() + if (4.toDouble() !in 1.0F .. 3.0F != !range0.contains(4.toDouble())) throw AssertionError() + if (!(4.toDouble() in 1.0F .. 3.0F) != !range0.contains(4.toDouble())) throw AssertionError() + if (!(4.toDouble() !in 1.0F .. 3.0F) != range0.contains(4.toDouble())) throw AssertionError() // no local optimizations if (element11 in 1.0F .. 3.0F != range0.contains(element11)) throw AssertionError() if (element11 !in 1.0F .. 3.0F != !range0.contains(element11)) throw AssertionError() @@ -276,324 +204,12 @@ fun testR0xE11() { if (!(element11 !in 1.0F .. 3.0F) != range0.contains(element11)) throw AssertionError() } -fun testR0xE12() { - // with possible local optimizations - if (1.toByte() in 1.0F .. 3.0F != range0.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in 1.0F .. 3.0F != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in 1.0F .. 3.0F) != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in 1.0F .. 3.0F) != range0.contains(1.toByte())) throw AssertionError() - // no local optimizations - if (element12 in 1.0F .. 3.0F != range0.contains(element12)) throw AssertionError() - if (element12 !in 1.0F .. 3.0F != !range0.contains(element12)) throw AssertionError() - if (!(element12 in 1.0F .. 3.0F) != !range0.contains(element12)) throw AssertionError() - if (!(element12 !in 1.0F .. 3.0F) != range0.contains(element12)) throw AssertionError() -} - -fun testR0xE13() { - // with possible local optimizations - if (1.toShort() in 1.0F .. 3.0F != range0.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in 1.0F .. 3.0F != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in 1.0F .. 3.0F) != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in 1.0F .. 3.0F) != range0.contains(1.toShort())) throw AssertionError() - // no local optimizations - if (element13 in 1.0F .. 3.0F != range0.contains(element13)) throw AssertionError() - if (element13 !in 1.0F .. 3.0F != !range0.contains(element13)) throw AssertionError() - if (!(element13 in 1.0F .. 3.0F) != !range0.contains(element13)) throw AssertionError() - if (!(element13 !in 1.0F .. 3.0F) != range0.contains(element13)) throw AssertionError() -} - -fun testR0xE14() { - // with possible local optimizations - if (1 in 1.0F .. 3.0F != range0.contains(1)) throw AssertionError() - if (1 !in 1.0F .. 3.0F != !range0.contains(1)) throw AssertionError() - if (!(1 in 1.0F .. 3.0F) != !range0.contains(1)) throw AssertionError() - if (!(1 !in 1.0F .. 3.0F) != range0.contains(1)) throw AssertionError() - // no local optimizations - if (element14 in 1.0F .. 3.0F != range0.contains(element14)) throw AssertionError() - if (element14 !in 1.0F .. 3.0F != !range0.contains(element14)) throw AssertionError() - if (!(element14 in 1.0F .. 3.0F) != !range0.contains(element14)) throw AssertionError() - if (!(element14 !in 1.0F .. 3.0F) != range0.contains(element14)) throw AssertionError() -} - -fun testR0xE15() { - // with possible local optimizations - if (1.toLong() in 1.0F .. 3.0F != range0.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in 1.0F .. 3.0F != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in 1.0F .. 3.0F) != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in 1.0F .. 3.0F) != range0.contains(1.toLong())) throw AssertionError() - // no local optimizations - if (element15 in 1.0F .. 3.0F != range0.contains(element15)) throw AssertionError() - if (element15 !in 1.0F .. 3.0F != !range0.contains(element15)) throw AssertionError() - if (!(element15 in 1.0F .. 3.0F) != !range0.contains(element15)) throw AssertionError() - if (!(element15 !in 1.0F .. 3.0F) != range0.contains(element15)) throw AssertionError() -} - -fun testR0xE16() { - // with possible local optimizations - if (1.toFloat() in 1.0F .. 3.0F != range0.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in 1.0F .. 3.0F != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in 1.0F .. 3.0F) != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in 1.0F .. 3.0F) != range0.contains(1.toFloat())) throw AssertionError() - // no local optimizations - if (element16 in 1.0F .. 3.0F != range0.contains(element16)) throw AssertionError() - if (element16 !in 1.0F .. 3.0F != !range0.contains(element16)) throw AssertionError() - if (!(element16 in 1.0F .. 3.0F) != !range0.contains(element16)) throw AssertionError() - if (!(element16 !in 1.0F .. 3.0F) != range0.contains(element16)) throw AssertionError() -} - -fun testR0xE17() { - // with possible local optimizations - if (1.toDouble() in 1.0F .. 3.0F != range0.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in 1.0F .. 3.0F != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in 1.0F .. 3.0F) != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in 1.0F .. 3.0F) != range0.contains(1.toDouble())) throw AssertionError() - // no local optimizations - if (element17 in 1.0F .. 3.0F != range0.contains(element17)) throw AssertionError() - if (element17 !in 1.0F .. 3.0F != !range0.contains(element17)) throw AssertionError() - if (!(element17 in 1.0F .. 3.0F) != !range0.contains(element17)) throw AssertionError() - if (!(element17 !in 1.0F .. 3.0F) != range0.contains(element17)) throw AssertionError() -} - -fun testR0xE18() { - // with possible local optimizations - if (2.toByte() in 1.0F .. 3.0F != range0.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in 1.0F .. 3.0F != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in 1.0F .. 3.0F) != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in 1.0F .. 3.0F) != range0.contains(2.toByte())) throw AssertionError() - // no local optimizations - if (element18 in 1.0F .. 3.0F != range0.contains(element18)) throw AssertionError() - if (element18 !in 1.0F .. 3.0F != !range0.contains(element18)) throw AssertionError() - if (!(element18 in 1.0F .. 3.0F) != !range0.contains(element18)) throw AssertionError() - if (!(element18 !in 1.0F .. 3.0F) != range0.contains(element18)) throw AssertionError() -} - -fun testR0xE19() { - // with possible local optimizations - if (2.toShort() in 1.0F .. 3.0F != range0.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in 1.0F .. 3.0F != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in 1.0F .. 3.0F) != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in 1.0F .. 3.0F) != range0.contains(2.toShort())) throw AssertionError() - // no local optimizations - if (element19 in 1.0F .. 3.0F != range0.contains(element19)) throw AssertionError() - if (element19 !in 1.0F .. 3.0F != !range0.contains(element19)) throw AssertionError() - if (!(element19 in 1.0F .. 3.0F) != !range0.contains(element19)) throw AssertionError() - if (!(element19 !in 1.0F .. 3.0F) != range0.contains(element19)) throw AssertionError() -} - -fun testR0xE20() { - // with possible local optimizations - if (2 in 1.0F .. 3.0F != range0.contains(2)) throw AssertionError() - if (2 !in 1.0F .. 3.0F != !range0.contains(2)) throw AssertionError() - if (!(2 in 1.0F .. 3.0F) != !range0.contains(2)) throw AssertionError() - if (!(2 !in 1.0F .. 3.0F) != range0.contains(2)) throw AssertionError() - // no local optimizations - if (element20 in 1.0F .. 3.0F != range0.contains(element20)) throw AssertionError() - if (element20 !in 1.0F .. 3.0F != !range0.contains(element20)) throw AssertionError() - if (!(element20 in 1.0F .. 3.0F) != !range0.contains(element20)) throw AssertionError() - if (!(element20 !in 1.0F .. 3.0F) != range0.contains(element20)) throw AssertionError() -} - -fun testR0xE21() { - // with possible local optimizations - if (2.toLong() in 1.0F .. 3.0F != range0.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in 1.0F .. 3.0F != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in 1.0F .. 3.0F) != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in 1.0F .. 3.0F) != range0.contains(2.toLong())) throw AssertionError() - // no local optimizations - if (element21 in 1.0F .. 3.0F != range0.contains(element21)) throw AssertionError() - if (element21 !in 1.0F .. 3.0F != !range0.contains(element21)) throw AssertionError() - if (!(element21 in 1.0F .. 3.0F) != !range0.contains(element21)) throw AssertionError() - if (!(element21 !in 1.0F .. 3.0F) != range0.contains(element21)) throw AssertionError() -} - -fun testR0xE22() { - // with possible local optimizations - if (2.toFloat() in 1.0F .. 3.0F != range0.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in 1.0F .. 3.0F != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in 1.0F .. 3.0F) != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in 1.0F .. 3.0F) != range0.contains(2.toFloat())) throw AssertionError() - // no local optimizations - if (element22 in 1.0F .. 3.0F != range0.contains(element22)) throw AssertionError() - if (element22 !in 1.0F .. 3.0F != !range0.contains(element22)) throw AssertionError() - if (!(element22 in 1.0F .. 3.0F) != !range0.contains(element22)) throw AssertionError() - if (!(element22 !in 1.0F .. 3.0F) != range0.contains(element22)) throw AssertionError() -} - -fun testR0xE23() { - // with possible local optimizations - if (2.toDouble() in 1.0F .. 3.0F != range0.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in 1.0F .. 3.0F != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in 1.0F .. 3.0F) != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in 1.0F .. 3.0F) != range0.contains(2.toDouble())) throw AssertionError() - // no local optimizations - if (element23 in 1.0F .. 3.0F != range0.contains(element23)) throw AssertionError() - if (element23 !in 1.0F .. 3.0F != !range0.contains(element23)) throw AssertionError() - if (!(element23 in 1.0F .. 3.0F) != !range0.contains(element23)) throw AssertionError() - if (!(element23 !in 1.0F .. 3.0F) != range0.contains(element23)) throw AssertionError() -} - -fun testR0xE24() { - // with possible local optimizations - if (3.toByte() in 1.0F .. 3.0F != range0.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in 1.0F .. 3.0F != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in 1.0F .. 3.0F) != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in 1.0F .. 3.0F) != range0.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in 1.0F .. 3.0F != range0.contains(element24)) throw AssertionError() - if (element24 !in 1.0F .. 3.0F != !range0.contains(element24)) throw AssertionError() - if (!(element24 in 1.0F .. 3.0F) != !range0.contains(element24)) throw AssertionError() - if (!(element24 !in 1.0F .. 3.0F) != range0.contains(element24)) throw AssertionError() -} - -fun testR0xE25() { - // with possible local optimizations - if (3.toShort() in 1.0F .. 3.0F != range0.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in 1.0F .. 3.0F != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in 1.0F .. 3.0F) != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in 1.0F .. 3.0F) != range0.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in 1.0F .. 3.0F != range0.contains(element25)) throw AssertionError() - if (element25 !in 1.0F .. 3.0F != !range0.contains(element25)) throw AssertionError() - if (!(element25 in 1.0F .. 3.0F) != !range0.contains(element25)) throw AssertionError() - if (!(element25 !in 1.0F .. 3.0F) != range0.contains(element25)) throw AssertionError() -} - -fun testR0xE26() { - // with possible local optimizations - if (3 in 1.0F .. 3.0F != range0.contains(3)) throw AssertionError() - if (3 !in 1.0F .. 3.0F != !range0.contains(3)) throw AssertionError() - if (!(3 in 1.0F .. 3.0F) != !range0.contains(3)) throw AssertionError() - if (!(3 !in 1.0F .. 3.0F) != range0.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in 1.0F .. 3.0F != range0.contains(element26)) throw AssertionError() - if (element26 !in 1.0F .. 3.0F != !range0.contains(element26)) throw AssertionError() - if (!(element26 in 1.0F .. 3.0F) != !range0.contains(element26)) throw AssertionError() - if (!(element26 !in 1.0F .. 3.0F) != range0.contains(element26)) throw AssertionError() -} - -fun testR0xE27() { - // with possible local optimizations - if (3.toLong() in 1.0F .. 3.0F != range0.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in 1.0F .. 3.0F != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in 1.0F .. 3.0F) != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in 1.0F .. 3.0F) != range0.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in 1.0F .. 3.0F != range0.contains(element27)) throw AssertionError() - if (element27 !in 1.0F .. 3.0F != !range0.contains(element27)) throw AssertionError() - if (!(element27 in 1.0F .. 3.0F) != !range0.contains(element27)) throw AssertionError() - if (!(element27 !in 1.0F .. 3.0F) != range0.contains(element27)) throw AssertionError() -} - -fun testR0xE28() { - // with possible local optimizations - if (3.toFloat() in 1.0F .. 3.0F != range0.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in 1.0F .. 3.0F != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in 1.0F .. 3.0F) != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in 1.0F .. 3.0F) != range0.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in 1.0F .. 3.0F != range0.contains(element28)) throw AssertionError() - if (element28 !in 1.0F .. 3.0F != !range0.contains(element28)) throw AssertionError() - if (!(element28 in 1.0F .. 3.0F) != !range0.contains(element28)) throw AssertionError() - if (!(element28 !in 1.0F .. 3.0F) != range0.contains(element28)) throw AssertionError() -} - -fun testR0xE29() { - // with possible local optimizations - if (3.toDouble() in 1.0F .. 3.0F != range0.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in 1.0F .. 3.0F != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in 1.0F .. 3.0F) != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in 1.0F .. 3.0F) != range0.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in 1.0F .. 3.0F != range0.contains(element29)) throw AssertionError() - if (element29 !in 1.0F .. 3.0F != !range0.contains(element29)) throw AssertionError() - if (!(element29 in 1.0F .. 3.0F) != !range0.contains(element29)) throw AssertionError() - if (!(element29 !in 1.0F .. 3.0F) != range0.contains(element29)) throw AssertionError() -} - -fun testR0xE30() { - // with possible local optimizations - if (4.toByte() in 1.0F .. 3.0F != range0.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in 1.0F .. 3.0F != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in 1.0F .. 3.0F) != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in 1.0F .. 3.0F) != range0.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in 1.0F .. 3.0F != range0.contains(element30)) throw AssertionError() - if (element30 !in 1.0F .. 3.0F != !range0.contains(element30)) throw AssertionError() - if (!(element30 in 1.0F .. 3.0F) != !range0.contains(element30)) throw AssertionError() - if (!(element30 !in 1.0F .. 3.0F) != range0.contains(element30)) throw AssertionError() -} - -fun testR0xE31() { - // with possible local optimizations - if (4.toShort() in 1.0F .. 3.0F != range0.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in 1.0F .. 3.0F != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in 1.0F .. 3.0F) != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in 1.0F .. 3.0F) != range0.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in 1.0F .. 3.0F != range0.contains(element31)) throw AssertionError() - if (element31 !in 1.0F .. 3.0F != !range0.contains(element31)) throw AssertionError() - if (!(element31 in 1.0F .. 3.0F) != !range0.contains(element31)) throw AssertionError() - if (!(element31 !in 1.0F .. 3.0F) != range0.contains(element31)) throw AssertionError() -} - -fun testR0xE32() { - // with possible local optimizations - if (4 in 1.0F .. 3.0F != range0.contains(4)) throw AssertionError() - if (4 !in 1.0F .. 3.0F != !range0.contains(4)) throw AssertionError() - if (!(4 in 1.0F .. 3.0F) != !range0.contains(4)) throw AssertionError() - if (!(4 !in 1.0F .. 3.0F) != range0.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in 1.0F .. 3.0F != range0.contains(element32)) throw AssertionError() - if (element32 !in 1.0F .. 3.0F != !range0.contains(element32)) throw AssertionError() - if (!(element32 in 1.0F .. 3.0F) != !range0.contains(element32)) throw AssertionError() - if (!(element32 !in 1.0F .. 3.0F) != range0.contains(element32)) throw AssertionError() -} - -fun testR0xE33() { - // with possible local optimizations - if (4.toLong() in 1.0F .. 3.0F != range0.contains(4.toLong())) throw AssertionError() - if (4.toLong() !in 1.0F .. 3.0F != !range0.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() in 1.0F .. 3.0F) != !range0.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() !in 1.0F .. 3.0F) != range0.contains(4.toLong())) throw AssertionError() - // no local optimizations - if (element33 in 1.0F .. 3.0F != range0.contains(element33)) throw AssertionError() - if (element33 !in 1.0F .. 3.0F != !range0.contains(element33)) throw AssertionError() - if (!(element33 in 1.0F .. 3.0F) != !range0.contains(element33)) throw AssertionError() - if (!(element33 !in 1.0F .. 3.0F) != range0.contains(element33)) throw AssertionError() -} - -fun testR0xE34() { - // with possible local optimizations - if (4.toFloat() in 1.0F .. 3.0F != range0.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in 1.0F .. 3.0F != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in 1.0F .. 3.0F) != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in 1.0F .. 3.0F) != range0.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in 1.0F .. 3.0F != range0.contains(element34)) throw AssertionError() - if (element34 !in 1.0F .. 3.0F != !range0.contains(element34)) throw AssertionError() - if (!(element34 in 1.0F .. 3.0F) != !range0.contains(element34)) throw AssertionError() - if (!(element34 !in 1.0F .. 3.0F) != range0.contains(element34)) throw AssertionError() -} - -fun testR0xE35() { - // with possible local optimizations - if (4.toDouble() in 1.0F .. 3.0F != range0.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in 1.0F .. 3.0F != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in 1.0F .. 3.0F) != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in 1.0F .. 3.0F) != range0.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in 1.0F .. 3.0F != range0.contains(element35)) throw AssertionError() - if (element35 !in 1.0F .. 3.0F != !range0.contains(element35)) throw AssertionError() - if (!(element35 in 1.0F .. 3.0F) != !range0.contains(element35)) throw AssertionError() - if (!(element35 !in 1.0F .. 3.0F) != range0.contains(element35)) throw AssertionError() -} - fun testR1xE0() { // with possible local optimizations - if ((-1).toByte() in 3.0F .. 1.0F != range1.contains((-1).toByte())) throw AssertionError() - if ((-1).toByte() !in 3.0F .. 1.0F != !range1.contains((-1).toByte())) throw AssertionError() - if (!((-1).toByte() in 3.0F .. 1.0F) != !range1.contains((-1).toByte())) throw AssertionError() - if (!((-1).toByte() !in 3.0F .. 1.0F) != range1.contains((-1).toByte())) throw AssertionError() + if ((-1).toFloat() in 3.0F .. 1.0F != range1.contains((-1).toFloat())) throw AssertionError() + if ((-1).toFloat() !in 3.0F .. 1.0F != !range1.contains((-1).toFloat())) throw AssertionError() + if (!((-1).toFloat() in 3.0F .. 1.0F) != !range1.contains((-1).toFloat())) throw AssertionError() + if (!((-1).toFloat() !in 3.0F .. 1.0F) != range1.contains((-1).toFloat())) throw AssertionError() // no local optimizations if (element0 in 3.0F .. 1.0F != range1.contains(element0)) throw AssertionError() if (element0 !in 3.0F .. 1.0F != !range1.contains(element0)) throw AssertionError() @@ -603,10 +219,10 @@ fun testR1xE0() { fun testR1xE1() { // with possible local optimizations - if ((-1).toShort() in 3.0F .. 1.0F != range1.contains((-1).toShort())) throw AssertionError() - if ((-1).toShort() !in 3.0F .. 1.0F != !range1.contains((-1).toShort())) throw AssertionError() - if (!((-1).toShort() in 3.0F .. 1.0F) != !range1.contains((-1).toShort())) throw AssertionError() - if (!((-1).toShort() !in 3.0F .. 1.0F) != range1.contains((-1).toShort())) throw AssertionError() + if ((-1).toDouble() in 3.0F .. 1.0F != range1.contains((-1).toDouble())) throw AssertionError() + if ((-1).toDouble() !in 3.0F .. 1.0F != !range1.contains((-1).toDouble())) throw AssertionError() + if (!((-1).toDouble() in 3.0F .. 1.0F) != !range1.contains((-1).toDouble())) throw AssertionError() + if (!((-1).toDouble() !in 3.0F .. 1.0F) != range1.contains((-1).toDouble())) throw AssertionError() // no local optimizations if (element1 in 3.0F .. 1.0F != range1.contains(element1)) throw AssertionError() if (element1 !in 3.0F .. 1.0F != !range1.contains(element1)) throw AssertionError() @@ -616,10 +232,10 @@ fun testR1xE1() { fun testR1xE2() { // with possible local optimizations - if ((-1) in 3.0F .. 1.0F != range1.contains((-1))) throw AssertionError() - if ((-1) !in 3.0F .. 1.0F != !range1.contains((-1))) throw AssertionError() - if (!((-1) in 3.0F .. 1.0F) != !range1.contains((-1))) throw AssertionError() - if (!((-1) !in 3.0F .. 1.0F) != range1.contains((-1))) throw AssertionError() + if (0.toFloat() in 3.0F .. 1.0F != range1.contains(0.toFloat())) throw AssertionError() + if (0.toFloat() !in 3.0F .. 1.0F != !range1.contains(0.toFloat())) throw AssertionError() + if (!(0.toFloat() in 3.0F .. 1.0F) != !range1.contains(0.toFloat())) throw AssertionError() + if (!(0.toFloat() !in 3.0F .. 1.0F) != range1.contains(0.toFloat())) throw AssertionError() // no local optimizations if (element2 in 3.0F .. 1.0F != range1.contains(element2)) throw AssertionError() if (element2 !in 3.0F .. 1.0F != !range1.contains(element2)) throw AssertionError() @@ -629,10 +245,10 @@ fun testR1xE2() { fun testR1xE3() { // with possible local optimizations - if ((-1).toLong() in 3.0F .. 1.0F != range1.contains((-1).toLong())) throw AssertionError() - if ((-1).toLong() !in 3.0F .. 1.0F != !range1.contains((-1).toLong())) throw AssertionError() - if (!((-1).toLong() in 3.0F .. 1.0F) != !range1.contains((-1).toLong())) throw AssertionError() - if (!((-1).toLong() !in 3.0F .. 1.0F) != range1.contains((-1).toLong())) throw AssertionError() + if (0.toDouble() in 3.0F .. 1.0F != range1.contains(0.toDouble())) throw AssertionError() + if (0.toDouble() !in 3.0F .. 1.0F != !range1.contains(0.toDouble())) throw AssertionError() + if (!(0.toDouble() in 3.0F .. 1.0F) != !range1.contains(0.toDouble())) throw AssertionError() + if (!(0.toDouble() !in 3.0F .. 1.0F) != range1.contains(0.toDouble())) throw AssertionError() // no local optimizations if (element3 in 3.0F .. 1.0F != range1.contains(element3)) throw AssertionError() if (element3 !in 3.0F .. 1.0F != !range1.contains(element3)) throw AssertionError() @@ -642,10 +258,10 @@ fun testR1xE3() { fun testR1xE4() { // with possible local optimizations - if ((-1).toFloat() in 3.0F .. 1.0F != range1.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in 3.0F .. 1.0F != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in 3.0F .. 1.0F) != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in 3.0F .. 1.0F) != range1.contains((-1).toFloat())) throw AssertionError() + if (1.toFloat() in 3.0F .. 1.0F != range1.contains(1.toFloat())) throw AssertionError() + if (1.toFloat() !in 3.0F .. 1.0F != !range1.contains(1.toFloat())) throw AssertionError() + if (!(1.toFloat() in 3.0F .. 1.0F) != !range1.contains(1.toFloat())) throw AssertionError() + if (!(1.toFloat() !in 3.0F .. 1.0F) != range1.contains(1.toFloat())) throw AssertionError() // no local optimizations if (element4 in 3.0F .. 1.0F != range1.contains(element4)) throw AssertionError() if (element4 !in 3.0F .. 1.0F != !range1.contains(element4)) throw AssertionError() @@ -655,10 +271,10 @@ fun testR1xE4() { fun testR1xE5() { // with possible local optimizations - if ((-1).toDouble() in 3.0F .. 1.0F != range1.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in 3.0F .. 1.0F != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in 3.0F .. 1.0F) != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in 3.0F .. 1.0F) != range1.contains((-1).toDouble())) throw AssertionError() + if (1.toDouble() in 3.0F .. 1.0F != range1.contains(1.toDouble())) throw AssertionError() + if (1.toDouble() !in 3.0F .. 1.0F != !range1.contains(1.toDouble())) throw AssertionError() + if (!(1.toDouble() in 3.0F .. 1.0F) != !range1.contains(1.toDouble())) throw AssertionError() + if (!(1.toDouble() !in 3.0F .. 1.0F) != range1.contains(1.toDouble())) throw AssertionError() // no local optimizations if (element5 in 3.0F .. 1.0F != range1.contains(element5)) throw AssertionError() if (element5 !in 3.0F .. 1.0F != !range1.contains(element5)) throw AssertionError() @@ -668,10 +284,10 @@ fun testR1xE5() { fun testR1xE6() { // with possible local optimizations - if (0.toByte() in 3.0F .. 1.0F != range1.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in 3.0F .. 1.0F != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in 3.0F .. 1.0F) != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in 3.0F .. 1.0F) != range1.contains(0.toByte())) throw AssertionError() + if (2.toFloat() in 3.0F .. 1.0F != range1.contains(2.toFloat())) throw AssertionError() + if (2.toFloat() !in 3.0F .. 1.0F != !range1.contains(2.toFloat())) throw AssertionError() + if (!(2.toFloat() in 3.0F .. 1.0F) != !range1.contains(2.toFloat())) throw AssertionError() + if (!(2.toFloat() !in 3.0F .. 1.0F) != range1.contains(2.toFloat())) throw AssertionError() // no local optimizations if (element6 in 3.0F .. 1.0F != range1.contains(element6)) throw AssertionError() if (element6 !in 3.0F .. 1.0F != !range1.contains(element6)) throw AssertionError() @@ -681,10 +297,10 @@ fun testR1xE6() { fun testR1xE7() { // with possible local optimizations - if (0.toShort() in 3.0F .. 1.0F != range1.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in 3.0F .. 1.0F != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in 3.0F .. 1.0F) != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in 3.0F .. 1.0F) != range1.contains(0.toShort())) throw AssertionError() + if (2.toDouble() in 3.0F .. 1.0F != range1.contains(2.toDouble())) throw AssertionError() + if (2.toDouble() !in 3.0F .. 1.0F != !range1.contains(2.toDouble())) throw AssertionError() + if (!(2.toDouble() in 3.0F .. 1.0F) != !range1.contains(2.toDouble())) throw AssertionError() + if (!(2.toDouble() !in 3.0F .. 1.0F) != range1.contains(2.toDouble())) throw AssertionError() // no local optimizations if (element7 in 3.0F .. 1.0F != range1.contains(element7)) throw AssertionError() if (element7 !in 3.0F .. 1.0F != !range1.contains(element7)) throw AssertionError() @@ -694,10 +310,10 @@ fun testR1xE7() { fun testR1xE8() { // with possible local optimizations - if (0 in 3.0F .. 1.0F != range1.contains(0)) throw AssertionError() - if (0 !in 3.0F .. 1.0F != !range1.contains(0)) throw AssertionError() - if (!(0 in 3.0F .. 1.0F) != !range1.contains(0)) throw AssertionError() - if (!(0 !in 3.0F .. 1.0F) != range1.contains(0)) throw AssertionError() + if (3.toFloat() in 3.0F .. 1.0F != range1.contains(3.toFloat())) throw AssertionError() + if (3.toFloat() !in 3.0F .. 1.0F != !range1.contains(3.toFloat())) throw AssertionError() + if (!(3.toFloat() in 3.0F .. 1.0F) != !range1.contains(3.toFloat())) throw AssertionError() + if (!(3.toFloat() !in 3.0F .. 1.0F) != range1.contains(3.toFloat())) throw AssertionError() // no local optimizations if (element8 in 3.0F .. 1.0F != range1.contains(element8)) throw AssertionError() if (element8 !in 3.0F .. 1.0F != !range1.contains(element8)) throw AssertionError() @@ -707,10 +323,10 @@ fun testR1xE8() { fun testR1xE9() { // with possible local optimizations - if (0.toLong() in 3.0F .. 1.0F != range1.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in 3.0F .. 1.0F != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in 3.0F .. 1.0F) != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in 3.0F .. 1.0F) != range1.contains(0.toLong())) throw AssertionError() + if (3.toDouble() in 3.0F .. 1.0F != range1.contains(3.toDouble())) throw AssertionError() + if (3.toDouble() !in 3.0F .. 1.0F != !range1.contains(3.toDouble())) throw AssertionError() + if (!(3.toDouble() in 3.0F .. 1.0F) != !range1.contains(3.toDouble())) throw AssertionError() + if (!(3.toDouble() !in 3.0F .. 1.0F) != range1.contains(3.toDouble())) throw AssertionError() // no local optimizations if (element9 in 3.0F .. 1.0F != range1.contains(element9)) throw AssertionError() if (element9 !in 3.0F .. 1.0F != !range1.contains(element9)) throw AssertionError() @@ -720,10 +336,10 @@ fun testR1xE9() { fun testR1xE10() { // with possible local optimizations - if (0.toFloat() in 3.0F .. 1.0F != range1.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in 3.0F .. 1.0F != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in 3.0F .. 1.0F) != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in 3.0F .. 1.0F) != range1.contains(0.toFloat())) throw AssertionError() + if (4.toFloat() in 3.0F .. 1.0F != range1.contains(4.toFloat())) throw AssertionError() + if (4.toFloat() !in 3.0F .. 1.0F != !range1.contains(4.toFloat())) throw AssertionError() + if (!(4.toFloat() in 3.0F .. 1.0F) != !range1.contains(4.toFloat())) throw AssertionError() + if (!(4.toFloat() !in 3.0F .. 1.0F) != range1.contains(4.toFloat())) throw AssertionError() // no local optimizations if (element10 in 3.0F .. 1.0F != range1.contains(element10)) throw AssertionError() if (element10 !in 3.0F .. 1.0F != !range1.contains(element10)) throw AssertionError() @@ -733,10 +349,10 @@ fun testR1xE10() { fun testR1xE11() { // with possible local optimizations - if (0.toDouble() in 3.0F .. 1.0F != range1.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in 3.0F .. 1.0F != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in 3.0F .. 1.0F) != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in 3.0F .. 1.0F) != range1.contains(0.toDouble())) throw AssertionError() + if (4.toDouble() in 3.0F .. 1.0F != range1.contains(4.toDouble())) throw AssertionError() + if (4.toDouble() !in 3.0F .. 1.0F != !range1.contains(4.toDouble())) throw AssertionError() + if (!(4.toDouble() in 3.0F .. 1.0F) != !range1.contains(4.toDouble())) throw AssertionError() + if (!(4.toDouble() !in 3.0F .. 1.0F) != range1.contains(4.toDouble())) throw AssertionError() // no local optimizations if (element11 in 3.0F .. 1.0F != range1.contains(element11)) throw AssertionError() if (element11 !in 3.0F .. 1.0F != !range1.contains(element11)) throw AssertionError() @@ -744,316 +360,4 @@ fun testR1xE11() { if (!(element11 !in 3.0F .. 1.0F) != range1.contains(element11)) throw AssertionError() } -fun testR1xE12() { - // with possible local optimizations - if (1.toByte() in 3.0F .. 1.0F != range1.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in 3.0F .. 1.0F != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in 3.0F .. 1.0F) != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in 3.0F .. 1.0F) != range1.contains(1.toByte())) throw AssertionError() - // no local optimizations - if (element12 in 3.0F .. 1.0F != range1.contains(element12)) throw AssertionError() - if (element12 !in 3.0F .. 1.0F != !range1.contains(element12)) throw AssertionError() - if (!(element12 in 3.0F .. 1.0F) != !range1.contains(element12)) throw AssertionError() - if (!(element12 !in 3.0F .. 1.0F) != range1.contains(element12)) throw AssertionError() -} - -fun testR1xE13() { - // with possible local optimizations - if (1.toShort() in 3.0F .. 1.0F != range1.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in 3.0F .. 1.0F != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in 3.0F .. 1.0F) != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in 3.0F .. 1.0F) != range1.contains(1.toShort())) throw AssertionError() - // no local optimizations - if (element13 in 3.0F .. 1.0F != range1.contains(element13)) throw AssertionError() - if (element13 !in 3.0F .. 1.0F != !range1.contains(element13)) throw AssertionError() - if (!(element13 in 3.0F .. 1.0F) != !range1.contains(element13)) throw AssertionError() - if (!(element13 !in 3.0F .. 1.0F) != range1.contains(element13)) throw AssertionError() -} - -fun testR1xE14() { - // with possible local optimizations - if (1 in 3.0F .. 1.0F != range1.contains(1)) throw AssertionError() - if (1 !in 3.0F .. 1.0F != !range1.contains(1)) throw AssertionError() - if (!(1 in 3.0F .. 1.0F) != !range1.contains(1)) throw AssertionError() - if (!(1 !in 3.0F .. 1.0F) != range1.contains(1)) throw AssertionError() - // no local optimizations - if (element14 in 3.0F .. 1.0F != range1.contains(element14)) throw AssertionError() - if (element14 !in 3.0F .. 1.0F != !range1.contains(element14)) throw AssertionError() - if (!(element14 in 3.0F .. 1.0F) != !range1.contains(element14)) throw AssertionError() - if (!(element14 !in 3.0F .. 1.0F) != range1.contains(element14)) throw AssertionError() -} - -fun testR1xE15() { - // with possible local optimizations - if (1.toLong() in 3.0F .. 1.0F != range1.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in 3.0F .. 1.0F != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in 3.0F .. 1.0F) != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in 3.0F .. 1.0F) != range1.contains(1.toLong())) throw AssertionError() - // no local optimizations - if (element15 in 3.0F .. 1.0F != range1.contains(element15)) throw AssertionError() - if (element15 !in 3.0F .. 1.0F != !range1.contains(element15)) throw AssertionError() - if (!(element15 in 3.0F .. 1.0F) != !range1.contains(element15)) throw AssertionError() - if (!(element15 !in 3.0F .. 1.0F) != range1.contains(element15)) throw AssertionError() -} - -fun testR1xE16() { - // with possible local optimizations - if (1.toFloat() in 3.0F .. 1.0F != range1.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in 3.0F .. 1.0F != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in 3.0F .. 1.0F) != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in 3.0F .. 1.0F) != range1.contains(1.toFloat())) throw AssertionError() - // no local optimizations - if (element16 in 3.0F .. 1.0F != range1.contains(element16)) throw AssertionError() - if (element16 !in 3.0F .. 1.0F != !range1.contains(element16)) throw AssertionError() - if (!(element16 in 3.0F .. 1.0F) != !range1.contains(element16)) throw AssertionError() - if (!(element16 !in 3.0F .. 1.0F) != range1.contains(element16)) throw AssertionError() -} - -fun testR1xE17() { - // with possible local optimizations - if (1.toDouble() in 3.0F .. 1.0F != range1.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in 3.0F .. 1.0F != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in 3.0F .. 1.0F) != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in 3.0F .. 1.0F) != range1.contains(1.toDouble())) throw AssertionError() - // no local optimizations - if (element17 in 3.0F .. 1.0F != range1.contains(element17)) throw AssertionError() - if (element17 !in 3.0F .. 1.0F != !range1.contains(element17)) throw AssertionError() - if (!(element17 in 3.0F .. 1.0F) != !range1.contains(element17)) throw AssertionError() - if (!(element17 !in 3.0F .. 1.0F) != range1.contains(element17)) throw AssertionError() -} - -fun testR1xE18() { - // with possible local optimizations - if (2.toByte() in 3.0F .. 1.0F != range1.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in 3.0F .. 1.0F != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in 3.0F .. 1.0F) != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in 3.0F .. 1.0F) != range1.contains(2.toByte())) throw AssertionError() - // no local optimizations - if (element18 in 3.0F .. 1.0F != range1.contains(element18)) throw AssertionError() - if (element18 !in 3.0F .. 1.0F != !range1.contains(element18)) throw AssertionError() - if (!(element18 in 3.0F .. 1.0F) != !range1.contains(element18)) throw AssertionError() - if (!(element18 !in 3.0F .. 1.0F) != range1.contains(element18)) throw AssertionError() -} - -fun testR1xE19() { - // with possible local optimizations - if (2.toShort() in 3.0F .. 1.0F != range1.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in 3.0F .. 1.0F != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in 3.0F .. 1.0F) != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in 3.0F .. 1.0F) != range1.contains(2.toShort())) throw AssertionError() - // no local optimizations - if (element19 in 3.0F .. 1.0F != range1.contains(element19)) throw AssertionError() - if (element19 !in 3.0F .. 1.0F != !range1.contains(element19)) throw AssertionError() - if (!(element19 in 3.0F .. 1.0F) != !range1.contains(element19)) throw AssertionError() - if (!(element19 !in 3.0F .. 1.0F) != range1.contains(element19)) throw AssertionError() -} - -fun testR1xE20() { - // with possible local optimizations - if (2 in 3.0F .. 1.0F != range1.contains(2)) throw AssertionError() - if (2 !in 3.0F .. 1.0F != !range1.contains(2)) throw AssertionError() - if (!(2 in 3.0F .. 1.0F) != !range1.contains(2)) throw AssertionError() - if (!(2 !in 3.0F .. 1.0F) != range1.contains(2)) throw AssertionError() - // no local optimizations - if (element20 in 3.0F .. 1.0F != range1.contains(element20)) throw AssertionError() - if (element20 !in 3.0F .. 1.0F != !range1.contains(element20)) throw AssertionError() - if (!(element20 in 3.0F .. 1.0F) != !range1.contains(element20)) throw AssertionError() - if (!(element20 !in 3.0F .. 1.0F) != range1.contains(element20)) throw AssertionError() -} - -fun testR1xE21() { - // with possible local optimizations - if (2.toLong() in 3.0F .. 1.0F != range1.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in 3.0F .. 1.0F != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in 3.0F .. 1.0F) != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in 3.0F .. 1.0F) != range1.contains(2.toLong())) throw AssertionError() - // no local optimizations - if (element21 in 3.0F .. 1.0F != range1.contains(element21)) throw AssertionError() - if (element21 !in 3.0F .. 1.0F != !range1.contains(element21)) throw AssertionError() - if (!(element21 in 3.0F .. 1.0F) != !range1.contains(element21)) throw AssertionError() - if (!(element21 !in 3.0F .. 1.0F) != range1.contains(element21)) throw AssertionError() -} - -fun testR1xE22() { - // with possible local optimizations - if (2.toFloat() in 3.0F .. 1.0F != range1.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in 3.0F .. 1.0F != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in 3.0F .. 1.0F) != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in 3.0F .. 1.0F) != range1.contains(2.toFloat())) throw AssertionError() - // no local optimizations - if (element22 in 3.0F .. 1.0F != range1.contains(element22)) throw AssertionError() - if (element22 !in 3.0F .. 1.0F != !range1.contains(element22)) throw AssertionError() - if (!(element22 in 3.0F .. 1.0F) != !range1.contains(element22)) throw AssertionError() - if (!(element22 !in 3.0F .. 1.0F) != range1.contains(element22)) throw AssertionError() -} - -fun testR1xE23() { - // with possible local optimizations - if (2.toDouble() in 3.0F .. 1.0F != range1.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in 3.0F .. 1.0F != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in 3.0F .. 1.0F) != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in 3.0F .. 1.0F) != range1.contains(2.toDouble())) throw AssertionError() - // no local optimizations - if (element23 in 3.0F .. 1.0F != range1.contains(element23)) throw AssertionError() - if (element23 !in 3.0F .. 1.0F != !range1.contains(element23)) throw AssertionError() - if (!(element23 in 3.0F .. 1.0F) != !range1.contains(element23)) throw AssertionError() - if (!(element23 !in 3.0F .. 1.0F) != range1.contains(element23)) throw AssertionError() -} - -fun testR1xE24() { - // with possible local optimizations - if (3.toByte() in 3.0F .. 1.0F != range1.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in 3.0F .. 1.0F != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in 3.0F .. 1.0F) != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in 3.0F .. 1.0F) != range1.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in 3.0F .. 1.0F != range1.contains(element24)) throw AssertionError() - if (element24 !in 3.0F .. 1.0F != !range1.contains(element24)) throw AssertionError() - if (!(element24 in 3.0F .. 1.0F) != !range1.contains(element24)) throw AssertionError() - if (!(element24 !in 3.0F .. 1.0F) != range1.contains(element24)) throw AssertionError() -} - -fun testR1xE25() { - // with possible local optimizations - if (3.toShort() in 3.0F .. 1.0F != range1.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in 3.0F .. 1.0F != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in 3.0F .. 1.0F) != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in 3.0F .. 1.0F) != range1.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in 3.0F .. 1.0F != range1.contains(element25)) throw AssertionError() - if (element25 !in 3.0F .. 1.0F != !range1.contains(element25)) throw AssertionError() - if (!(element25 in 3.0F .. 1.0F) != !range1.contains(element25)) throw AssertionError() - if (!(element25 !in 3.0F .. 1.0F) != range1.contains(element25)) throw AssertionError() -} - -fun testR1xE26() { - // with possible local optimizations - if (3 in 3.0F .. 1.0F != range1.contains(3)) throw AssertionError() - if (3 !in 3.0F .. 1.0F != !range1.contains(3)) throw AssertionError() - if (!(3 in 3.0F .. 1.0F) != !range1.contains(3)) throw AssertionError() - if (!(3 !in 3.0F .. 1.0F) != range1.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in 3.0F .. 1.0F != range1.contains(element26)) throw AssertionError() - if (element26 !in 3.0F .. 1.0F != !range1.contains(element26)) throw AssertionError() - if (!(element26 in 3.0F .. 1.0F) != !range1.contains(element26)) throw AssertionError() - if (!(element26 !in 3.0F .. 1.0F) != range1.contains(element26)) throw AssertionError() -} - -fun testR1xE27() { - // with possible local optimizations - if (3.toLong() in 3.0F .. 1.0F != range1.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in 3.0F .. 1.0F != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in 3.0F .. 1.0F) != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in 3.0F .. 1.0F) != range1.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in 3.0F .. 1.0F != range1.contains(element27)) throw AssertionError() - if (element27 !in 3.0F .. 1.0F != !range1.contains(element27)) throw AssertionError() - if (!(element27 in 3.0F .. 1.0F) != !range1.contains(element27)) throw AssertionError() - if (!(element27 !in 3.0F .. 1.0F) != range1.contains(element27)) throw AssertionError() -} - -fun testR1xE28() { - // with possible local optimizations - if (3.toFloat() in 3.0F .. 1.0F != range1.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in 3.0F .. 1.0F != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in 3.0F .. 1.0F) != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in 3.0F .. 1.0F) != range1.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in 3.0F .. 1.0F != range1.contains(element28)) throw AssertionError() - if (element28 !in 3.0F .. 1.0F != !range1.contains(element28)) throw AssertionError() - if (!(element28 in 3.0F .. 1.0F) != !range1.contains(element28)) throw AssertionError() - if (!(element28 !in 3.0F .. 1.0F) != range1.contains(element28)) throw AssertionError() -} - -fun testR1xE29() { - // with possible local optimizations - if (3.toDouble() in 3.0F .. 1.0F != range1.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in 3.0F .. 1.0F != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in 3.0F .. 1.0F) != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in 3.0F .. 1.0F) != range1.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in 3.0F .. 1.0F != range1.contains(element29)) throw AssertionError() - if (element29 !in 3.0F .. 1.0F != !range1.contains(element29)) throw AssertionError() - if (!(element29 in 3.0F .. 1.0F) != !range1.contains(element29)) throw AssertionError() - if (!(element29 !in 3.0F .. 1.0F) != range1.contains(element29)) throw AssertionError() -} - -fun testR1xE30() { - // with possible local optimizations - if (4.toByte() in 3.0F .. 1.0F != range1.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in 3.0F .. 1.0F != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in 3.0F .. 1.0F) != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in 3.0F .. 1.0F) != range1.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in 3.0F .. 1.0F != range1.contains(element30)) throw AssertionError() - if (element30 !in 3.0F .. 1.0F != !range1.contains(element30)) throw AssertionError() - if (!(element30 in 3.0F .. 1.0F) != !range1.contains(element30)) throw AssertionError() - if (!(element30 !in 3.0F .. 1.0F) != range1.contains(element30)) throw AssertionError() -} - -fun testR1xE31() { - // with possible local optimizations - if (4.toShort() in 3.0F .. 1.0F != range1.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in 3.0F .. 1.0F != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in 3.0F .. 1.0F) != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in 3.0F .. 1.0F) != range1.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in 3.0F .. 1.0F != range1.contains(element31)) throw AssertionError() - if (element31 !in 3.0F .. 1.0F != !range1.contains(element31)) throw AssertionError() - if (!(element31 in 3.0F .. 1.0F) != !range1.contains(element31)) throw AssertionError() - if (!(element31 !in 3.0F .. 1.0F) != range1.contains(element31)) throw AssertionError() -} - -fun testR1xE32() { - // with possible local optimizations - if (4 in 3.0F .. 1.0F != range1.contains(4)) throw AssertionError() - if (4 !in 3.0F .. 1.0F != !range1.contains(4)) throw AssertionError() - if (!(4 in 3.0F .. 1.0F) != !range1.contains(4)) throw AssertionError() - if (!(4 !in 3.0F .. 1.0F) != range1.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in 3.0F .. 1.0F != range1.contains(element32)) throw AssertionError() - if (element32 !in 3.0F .. 1.0F != !range1.contains(element32)) throw AssertionError() - if (!(element32 in 3.0F .. 1.0F) != !range1.contains(element32)) throw AssertionError() - if (!(element32 !in 3.0F .. 1.0F) != range1.contains(element32)) throw AssertionError() -} - -fun testR1xE33() { - // with possible local optimizations - if (4.toLong() in 3.0F .. 1.0F != range1.contains(4.toLong())) throw AssertionError() - if (4.toLong() !in 3.0F .. 1.0F != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() in 3.0F .. 1.0F) != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() !in 3.0F .. 1.0F) != range1.contains(4.toLong())) throw AssertionError() - // no local optimizations - if (element33 in 3.0F .. 1.0F != range1.contains(element33)) throw AssertionError() - if (element33 !in 3.0F .. 1.0F != !range1.contains(element33)) throw AssertionError() - if (!(element33 in 3.0F .. 1.0F) != !range1.contains(element33)) throw AssertionError() - if (!(element33 !in 3.0F .. 1.0F) != range1.contains(element33)) throw AssertionError() -} - -fun testR1xE34() { - // with possible local optimizations - if (4.toFloat() in 3.0F .. 1.0F != range1.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in 3.0F .. 1.0F != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in 3.0F .. 1.0F) != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in 3.0F .. 1.0F) != range1.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in 3.0F .. 1.0F != range1.contains(element34)) throw AssertionError() - if (element34 !in 3.0F .. 1.0F != !range1.contains(element34)) throw AssertionError() - if (!(element34 in 3.0F .. 1.0F) != !range1.contains(element34)) throw AssertionError() - if (!(element34 !in 3.0F .. 1.0F) != range1.contains(element34)) throw AssertionError() -} - -fun testR1xE35() { - // with possible local optimizations - if (4.toDouble() in 3.0F .. 1.0F != range1.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in 3.0F .. 1.0F != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in 3.0F .. 1.0F) != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in 3.0F .. 1.0F) != range1.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in 3.0F .. 1.0F != range1.contains(element35)) throw AssertionError() - if (element35 !in 3.0F .. 1.0F != !range1.contains(element35)) throw AssertionError() - if (!(element35 in 3.0F .. 1.0F) != !range1.contains(element35)) throw AssertionError() - if (!(element35 !in 3.0F .. 1.0F) != range1.contains(element35)) throw AssertionError() -} - diff --git a/compiler/testData/codegen/box/ranges/contains/generated/intRangeLiteral.kt b/compiler/testData/codegen/box/ranges/contains/generated/intRangeLiteral.kt index 4c75741975c..c0795e90938 100644 --- a/compiler/testData/codegen/box/ranges/contains/generated/intRangeLiteral.kt +++ b/compiler/testData/codegen/box/ranges/contains/generated/intRangeLiteral.kt @@ -11,38 +11,26 @@ val element0 = (-1).toByte() val element1 = (-1).toShort() val element2 = (-1) val element3 = (-1).toLong() -val element4 = (-1).toFloat() -val element5 = (-1).toDouble() -val element6 = 0.toByte() -val element7 = 0.toShort() -val element8 = 0 -val element9 = 0.toLong() -val element10 = 0.toFloat() -val element11 = 0.toDouble() -val element12 = 1.toByte() -val element13 = 1.toShort() -val element14 = 1 -val element15 = 1.toLong() -val element16 = 1.toFloat() -val element17 = 1.toDouble() -val element18 = 2.toByte() -val element19 = 2.toShort() -val element20 = 2 -val element21 = 2.toLong() -val element22 = 2.toFloat() -val element23 = 2.toDouble() -val element24 = 3.toByte() -val element25 = 3.toShort() -val element26 = 3 -val element27 = 3.toLong() -val element28 = 3.toFloat() -val element29 = 3.toDouble() -val element30 = 4.toByte() -val element31 = 4.toShort() -val element32 = 4 -val element33 = 4.toLong() -val element34 = 4.toFloat() -val element35 = 4.toDouble() +val element4 = 0.toByte() +val element5 = 0.toShort() +val element6 = 0 +val element7 = 0.toLong() +val element8 = 1.toByte() +val element9 = 1.toShort() +val element10 = 1 +val element11 = 1.toLong() +val element12 = 2.toByte() +val element13 = 2.toShort() +val element14 = 2 +val element15 = 2.toLong() +val element16 = 3.toByte() +val element17 = 3.toShort() +val element18 = 3 +val element19 = 3.toLong() +val element20 = 4.toByte() +val element21 = 4.toShort() +val element22 = 4 +val element23 = 4.toLong() fun box(): String { testR0xE0() @@ -69,18 +57,6 @@ fun box(): String { testR0xE21() testR0xE22() testR0xE23() - testR0xE24() - testR0xE25() - testR0xE26() - testR0xE27() - testR0xE28() - testR0xE29() - testR0xE30() - testR0xE31() - testR0xE32() - testR0xE33() - testR0xE34() - testR0xE35() testR1xE0() testR1xE1() testR1xE2() @@ -105,18 +81,6 @@ fun box(): String { testR1xE21() testR1xE22() testR1xE23() - testR1xE24() - testR1xE25() - testR1xE26() - testR1xE27() - testR1xE28() - testR1xE29() - testR1xE30() - testR1xE31() - testR1xE32() - testR1xE33() - testR1xE34() - testR1xE35() return "OK" } @@ -174,10 +138,10 @@ fun testR0xE3() { fun testR0xE4() { // with possible local optimizations - if ((-1).toFloat() in 1 .. 3 != range0.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in 1 .. 3 != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in 1 .. 3) != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in 1 .. 3) != range0.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in 1 .. 3 != range0.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in 1 .. 3 != !range0.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in 1 .. 3) != !range0.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in 1 .. 3) != range0.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in 1 .. 3 != range0.contains(element4)) throw AssertionError() if (element4 !in 1 .. 3 != !range0.contains(element4)) throw AssertionError() @@ -187,10 +151,10 @@ fun testR0xE4() { fun testR0xE5() { // with possible local optimizations - if ((-1).toDouble() in 1 .. 3 != range0.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in 1 .. 3 != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in 1 .. 3) != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in 1 .. 3) != range0.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in 1 .. 3 != range0.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in 1 .. 3 != !range0.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in 1 .. 3) != !range0.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in 1 .. 3) != range0.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in 1 .. 3 != range0.contains(element5)) throw AssertionError() if (element5 !in 1 .. 3 != !range0.contains(element5)) throw AssertionError() @@ -200,10 +164,10 @@ fun testR0xE5() { fun testR0xE6() { // with possible local optimizations - if (0.toByte() in 1 .. 3 != range0.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in 1 .. 3 != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in 1 .. 3) != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in 1 .. 3) != range0.contains(0.toByte())) throw AssertionError() + if (0 in 1 .. 3 != range0.contains(0)) throw AssertionError() + if (0 !in 1 .. 3 != !range0.contains(0)) throw AssertionError() + if (!(0 in 1 .. 3) != !range0.contains(0)) throw AssertionError() + if (!(0 !in 1 .. 3) != range0.contains(0)) throw AssertionError() // no local optimizations if (element6 in 1 .. 3 != range0.contains(element6)) throw AssertionError() if (element6 !in 1 .. 3 != !range0.contains(element6)) throw AssertionError() @@ -213,10 +177,10 @@ fun testR0xE6() { fun testR0xE7() { // with possible local optimizations - if (0.toShort() in 1 .. 3 != range0.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in 1 .. 3 != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in 1 .. 3) != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in 1 .. 3) != range0.contains(0.toShort())) throw AssertionError() + if (0.toLong() in 1 .. 3 != range0.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in 1 .. 3 != !range0.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in 1 .. 3) != !range0.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in 1 .. 3) != range0.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in 1 .. 3 != range0.contains(element7)) throw AssertionError() if (element7 !in 1 .. 3 != !range0.contains(element7)) throw AssertionError() @@ -226,10 +190,10 @@ fun testR0xE7() { fun testR0xE8() { // with possible local optimizations - if (0 in 1 .. 3 != range0.contains(0)) throw AssertionError() - if (0 !in 1 .. 3 != !range0.contains(0)) throw AssertionError() - if (!(0 in 1 .. 3) != !range0.contains(0)) throw AssertionError() - if (!(0 !in 1 .. 3) != range0.contains(0)) throw AssertionError() + if (1.toByte() in 1 .. 3 != range0.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in 1 .. 3 != !range0.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in 1 .. 3) != !range0.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in 1 .. 3) != range0.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in 1 .. 3 != range0.contains(element8)) throw AssertionError() if (element8 !in 1 .. 3 != !range0.contains(element8)) throw AssertionError() @@ -239,10 +203,10 @@ fun testR0xE8() { fun testR0xE9() { // with possible local optimizations - if (0.toLong() in 1 .. 3 != range0.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in 1 .. 3 != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in 1 .. 3) != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in 1 .. 3) != range0.contains(0.toLong())) throw AssertionError() + if (1.toShort() in 1 .. 3 != range0.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in 1 .. 3 != !range0.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in 1 .. 3) != !range0.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in 1 .. 3) != range0.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in 1 .. 3 != range0.contains(element9)) throw AssertionError() if (element9 !in 1 .. 3 != !range0.contains(element9)) throw AssertionError() @@ -252,10 +216,10 @@ fun testR0xE9() { fun testR0xE10() { // with possible local optimizations - if (0.toFloat() in 1 .. 3 != range0.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in 1 .. 3 != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in 1 .. 3) != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in 1 .. 3) != range0.contains(0.toFloat())) throw AssertionError() + if (1 in 1 .. 3 != range0.contains(1)) throw AssertionError() + if (1 !in 1 .. 3 != !range0.contains(1)) throw AssertionError() + if (!(1 in 1 .. 3) != !range0.contains(1)) throw AssertionError() + if (!(1 !in 1 .. 3) != range0.contains(1)) throw AssertionError() // no local optimizations if (element10 in 1 .. 3 != range0.contains(element10)) throw AssertionError() if (element10 !in 1 .. 3 != !range0.contains(element10)) throw AssertionError() @@ -265,10 +229,10 @@ fun testR0xE10() { fun testR0xE11() { // with possible local optimizations - if (0.toDouble() in 1 .. 3 != range0.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in 1 .. 3 != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in 1 .. 3) != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in 1 .. 3) != range0.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in 1 .. 3 != range0.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in 1 .. 3 != !range0.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in 1 .. 3) != !range0.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in 1 .. 3) != range0.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in 1 .. 3 != range0.contains(element11)) throw AssertionError() if (element11 !in 1 .. 3 != !range0.contains(element11)) throw AssertionError() @@ -278,10 +242,10 @@ fun testR0xE11() { fun testR0xE12() { // with possible local optimizations - if (1.toByte() in 1 .. 3 != range0.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in 1 .. 3 != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in 1 .. 3) != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in 1 .. 3) != range0.contains(1.toByte())) throw AssertionError() + if (2.toByte() in 1 .. 3 != range0.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in 1 .. 3 != !range0.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in 1 .. 3) != !range0.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in 1 .. 3) != range0.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in 1 .. 3 != range0.contains(element12)) throw AssertionError() if (element12 !in 1 .. 3 != !range0.contains(element12)) throw AssertionError() @@ -291,10 +255,10 @@ fun testR0xE12() { fun testR0xE13() { // with possible local optimizations - if (1.toShort() in 1 .. 3 != range0.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in 1 .. 3 != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in 1 .. 3) != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in 1 .. 3) != range0.contains(1.toShort())) throw AssertionError() + if (2.toShort() in 1 .. 3 != range0.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in 1 .. 3 != !range0.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in 1 .. 3) != !range0.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in 1 .. 3) != range0.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in 1 .. 3 != range0.contains(element13)) throw AssertionError() if (element13 !in 1 .. 3 != !range0.contains(element13)) throw AssertionError() @@ -304,10 +268,10 @@ fun testR0xE13() { fun testR0xE14() { // with possible local optimizations - if (1 in 1 .. 3 != range0.contains(1)) throw AssertionError() - if (1 !in 1 .. 3 != !range0.contains(1)) throw AssertionError() - if (!(1 in 1 .. 3) != !range0.contains(1)) throw AssertionError() - if (!(1 !in 1 .. 3) != range0.contains(1)) throw AssertionError() + if (2 in 1 .. 3 != range0.contains(2)) throw AssertionError() + if (2 !in 1 .. 3 != !range0.contains(2)) throw AssertionError() + if (!(2 in 1 .. 3) != !range0.contains(2)) throw AssertionError() + if (!(2 !in 1 .. 3) != range0.contains(2)) throw AssertionError() // no local optimizations if (element14 in 1 .. 3 != range0.contains(element14)) throw AssertionError() if (element14 !in 1 .. 3 != !range0.contains(element14)) throw AssertionError() @@ -317,10 +281,10 @@ fun testR0xE14() { fun testR0xE15() { // with possible local optimizations - if (1.toLong() in 1 .. 3 != range0.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in 1 .. 3 != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in 1 .. 3) != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in 1 .. 3) != range0.contains(1.toLong())) throw AssertionError() + if (2.toLong() in 1 .. 3 != range0.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in 1 .. 3 != !range0.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in 1 .. 3) != !range0.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in 1 .. 3) != range0.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in 1 .. 3 != range0.contains(element15)) throw AssertionError() if (element15 !in 1 .. 3 != !range0.contains(element15)) throw AssertionError() @@ -330,10 +294,10 @@ fun testR0xE15() { fun testR0xE16() { // with possible local optimizations - if (1.toFloat() in 1 .. 3 != range0.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in 1 .. 3 != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in 1 .. 3) != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in 1 .. 3) != range0.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in 1 .. 3 != range0.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in 1 .. 3 != !range0.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in 1 .. 3) != !range0.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in 1 .. 3) != range0.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in 1 .. 3 != range0.contains(element16)) throw AssertionError() if (element16 !in 1 .. 3 != !range0.contains(element16)) throw AssertionError() @@ -343,10 +307,10 @@ fun testR0xE16() { fun testR0xE17() { // with possible local optimizations - if (1.toDouble() in 1 .. 3 != range0.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in 1 .. 3 != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in 1 .. 3) != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in 1 .. 3) != range0.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in 1 .. 3 != range0.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in 1 .. 3 != !range0.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in 1 .. 3) != !range0.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in 1 .. 3) != range0.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in 1 .. 3 != range0.contains(element17)) throw AssertionError() if (element17 !in 1 .. 3 != !range0.contains(element17)) throw AssertionError() @@ -356,10 +320,10 @@ fun testR0xE17() { fun testR0xE18() { // with possible local optimizations - if (2.toByte() in 1 .. 3 != range0.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in 1 .. 3 != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in 1 .. 3) != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in 1 .. 3) != range0.contains(2.toByte())) throw AssertionError() + if (3 in 1 .. 3 != range0.contains(3)) throw AssertionError() + if (3 !in 1 .. 3 != !range0.contains(3)) throw AssertionError() + if (!(3 in 1 .. 3) != !range0.contains(3)) throw AssertionError() + if (!(3 !in 1 .. 3) != range0.contains(3)) throw AssertionError() // no local optimizations if (element18 in 1 .. 3 != range0.contains(element18)) throw AssertionError() if (element18 !in 1 .. 3 != !range0.contains(element18)) throw AssertionError() @@ -369,10 +333,10 @@ fun testR0xE18() { fun testR0xE19() { // with possible local optimizations - if (2.toShort() in 1 .. 3 != range0.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in 1 .. 3 != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in 1 .. 3) != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in 1 .. 3) != range0.contains(2.toShort())) throw AssertionError() + if (3.toLong() in 1 .. 3 != range0.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in 1 .. 3 != !range0.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in 1 .. 3) != !range0.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in 1 .. 3) != range0.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in 1 .. 3 != range0.contains(element19)) throw AssertionError() if (element19 !in 1 .. 3 != !range0.contains(element19)) throw AssertionError() @@ -382,10 +346,10 @@ fun testR0xE19() { fun testR0xE20() { // with possible local optimizations - if (2 in 1 .. 3 != range0.contains(2)) throw AssertionError() - if (2 !in 1 .. 3 != !range0.contains(2)) throw AssertionError() - if (!(2 in 1 .. 3) != !range0.contains(2)) throw AssertionError() - if (!(2 !in 1 .. 3) != range0.contains(2)) throw AssertionError() + if (4.toByte() in 1 .. 3 != range0.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in 1 .. 3 != !range0.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in 1 .. 3) != !range0.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in 1 .. 3) != range0.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in 1 .. 3 != range0.contains(element20)) throw AssertionError() if (element20 !in 1 .. 3 != !range0.contains(element20)) throw AssertionError() @@ -395,10 +359,10 @@ fun testR0xE20() { fun testR0xE21() { // with possible local optimizations - if (2.toLong() in 1 .. 3 != range0.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in 1 .. 3 != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in 1 .. 3) != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in 1 .. 3) != range0.contains(2.toLong())) throw AssertionError() + if (4.toShort() in 1 .. 3 != range0.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in 1 .. 3 != !range0.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in 1 .. 3) != !range0.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in 1 .. 3) != range0.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in 1 .. 3 != range0.contains(element21)) throw AssertionError() if (element21 !in 1 .. 3 != !range0.contains(element21)) throw AssertionError() @@ -408,10 +372,10 @@ fun testR0xE21() { fun testR0xE22() { // with possible local optimizations - if (2.toFloat() in 1 .. 3 != range0.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in 1 .. 3 != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in 1 .. 3) != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in 1 .. 3) != range0.contains(2.toFloat())) throw AssertionError() + if (4 in 1 .. 3 != range0.contains(4)) throw AssertionError() + if (4 !in 1 .. 3 != !range0.contains(4)) throw AssertionError() + if (!(4 in 1 .. 3) != !range0.contains(4)) throw AssertionError() + if (!(4 !in 1 .. 3) != range0.contains(4)) throw AssertionError() // no local optimizations if (element22 in 1 .. 3 != range0.contains(element22)) throw AssertionError() if (element22 !in 1 .. 3 != !range0.contains(element22)) throw AssertionError() @@ -420,172 +384,16 @@ fun testR0xE22() { } fun testR0xE23() { - // with possible local optimizations - if (2.toDouble() in 1 .. 3 != range0.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in 1 .. 3 != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in 1 .. 3) != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in 1 .. 3) != range0.contains(2.toDouble())) throw AssertionError() - // no local optimizations - if (element23 in 1 .. 3 != range0.contains(element23)) throw AssertionError() - if (element23 !in 1 .. 3 != !range0.contains(element23)) throw AssertionError() - if (!(element23 in 1 .. 3) != !range0.contains(element23)) throw AssertionError() - if (!(element23 !in 1 .. 3) != range0.contains(element23)) throw AssertionError() -} - -fun testR0xE24() { - // with possible local optimizations - if (3.toByte() in 1 .. 3 != range0.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in 1 .. 3 != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in 1 .. 3) != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in 1 .. 3) != range0.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in 1 .. 3 != range0.contains(element24)) throw AssertionError() - if (element24 !in 1 .. 3 != !range0.contains(element24)) throw AssertionError() - if (!(element24 in 1 .. 3) != !range0.contains(element24)) throw AssertionError() - if (!(element24 !in 1 .. 3) != range0.contains(element24)) throw AssertionError() -} - -fun testR0xE25() { - // with possible local optimizations - if (3.toShort() in 1 .. 3 != range0.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in 1 .. 3 != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in 1 .. 3) != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in 1 .. 3) != range0.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in 1 .. 3 != range0.contains(element25)) throw AssertionError() - if (element25 !in 1 .. 3 != !range0.contains(element25)) throw AssertionError() - if (!(element25 in 1 .. 3) != !range0.contains(element25)) throw AssertionError() - if (!(element25 !in 1 .. 3) != range0.contains(element25)) throw AssertionError() -} - -fun testR0xE26() { - // with possible local optimizations - if (3 in 1 .. 3 != range0.contains(3)) throw AssertionError() - if (3 !in 1 .. 3 != !range0.contains(3)) throw AssertionError() - if (!(3 in 1 .. 3) != !range0.contains(3)) throw AssertionError() - if (!(3 !in 1 .. 3) != range0.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in 1 .. 3 != range0.contains(element26)) throw AssertionError() - if (element26 !in 1 .. 3 != !range0.contains(element26)) throw AssertionError() - if (!(element26 in 1 .. 3) != !range0.contains(element26)) throw AssertionError() - if (!(element26 !in 1 .. 3) != range0.contains(element26)) throw AssertionError() -} - -fun testR0xE27() { - // with possible local optimizations - if (3.toLong() in 1 .. 3 != range0.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in 1 .. 3 != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in 1 .. 3) != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in 1 .. 3) != range0.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in 1 .. 3 != range0.contains(element27)) throw AssertionError() - if (element27 !in 1 .. 3 != !range0.contains(element27)) throw AssertionError() - if (!(element27 in 1 .. 3) != !range0.contains(element27)) throw AssertionError() - if (!(element27 !in 1 .. 3) != range0.contains(element27)) throw AssertionError() -} - -fun testR0xE28() { - // with possible local optimizations - if (3.toFloat() in 1 .. 3 != range0.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in 1 .. 3 != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in 1 .. 3) != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in 1 .. 3) != range0.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in 1 .. 3 != range0.contains(element28)) throw AssertionError() - if (element28 !in 1 .. 3 != !range0.contains(element28)) throw AssertionError() - if (!(element28 in 1 .. 3) != !range0.contains(element28)) throw AssertionError() - if (!(element28 !in 1 .. 3) != range0.contains(element28)) throw AssertionError() -} - -fun testR0xE29() { - // with possible local optimizations - if (3.toDouble() in 1 .. 3 != range0.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in 1 .. 3 != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in 1 .. 3) != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in 1 .. 3) != range0.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in 1 .. 3 != range0.contains(element29)) throw AssertionError() - if (element29 !in 1 .. 3 != !range0.contains(element29)) throw AssertionError() - if (!(element29 in 1 .. 3) != !range0.contains(element29)) throw AssertionError() - if (!(element29 !in 1 .. 3) != range0.contains(element29)) throw AssertionError() -} - -fun testR0xE30() { - // with possible local optimizations - if (4.toByte() in 1 .. 3 != range0.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in 1 .. 3 != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in 1 .. 3) != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in 1 .. 3) != range0.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in 1 .. 3 != range0.contains(element30)) throw AssertionError() - if (element30 !in 1 .. 3 != !range0.contains(element30)) throw AssertionError() - if (!(element30 in 1 .. 3) != !range0.contains(element30)) throw AssertionError() - if (!(element30 !in 1 .. 3) != range0.contains(element30)) throw AssertionError() -} - -fun testR0xE31() { - // with possible local optimizations - if (4.toShort() in 1 .. 3 != range0.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in 1 .. 3 != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in 1 .. 3) != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in 1 .. 3) != range0.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in 1 .. 3 != range0.contains(element31)) throw AssertionError() - if (element31 !in 1 .. 3 != !range0.contains(element31)) throw AssertionError() - if (!(element31 in 1 .. 3) != !range0.contains(element31)) throw AssertionError() - if (!(element31 !in 1 .. 3) != range0.contains(element31)) throw AssertionError() -} - -fun testR0xE32() { - // with possible local optimizations - if (4 in 1 .. 3 != range0.contains(4)) throw AssertionError() - if (4 !in 1 .. 3 != !range0.contains(4)) throw AssertionError() - if (!(4 in 1 .. 3) != !range0.contains(4)) throw AssertionError() - if (!(4 !in 1 .. 3) != range0.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in 1 .. 3 != range0.contains(element32)) throw AssertionError() - if (element32 !in 1 .. 3 != !range0.contains(element32)) throw AssertionError() - if (!(element32 in 1 .. 3) != !range0.contains(element32)) throw AssertionError() - if (!(element32 !in 1 .. 3) != range0.contains(element32)) throw AssertionError() -} - -fun testR0xE33() { // with possible local optimizations if (4.toLong() in 1 .. 3 != range0.contains(4.toLong())) throw AssertionError() if (4.toLong() !in 1 .. 3 != !range0.contains(4.toLong())) throw AssertionError() if (!(4.toLong() in 1 .. 3) != !range0.contains(4.toLong())) throw AssertionError() if (!(4.toLong() !in 1 .. 3) != range0.contains(4.toLong())) throw AssertionError() // no local optimizations - if (element33 in 1 .. 3 != range0.contains(element33)) throw AssertionError() - if (element33 !in 1 .. 3 != !range0.contains(element33)) throw AssertionError() - if (!(element33 in 1 .. 3) != !range0.contains(element33)) throw AssertionError() - if (!(element33 !in 1 .. 3) != range0.contains(element33)) throw AssertionError() -} - -fun testR0xE34() { - // with possible local optimizations - if (4.toFloat() in 1 .. 3 != range0.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in 1 .. 3 != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in 1 .. 3) != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in 1 .. 3) != range0.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in 1 .. 3 != range0.contains(element34)) throw AssertionError() - if (element34 !in 1 .. 3 != !range0.contains(element34)) throw AssertionError() - if (!(element34 in 1 .. 3) != !range0.contains(element34)) throw AssertionError() - if (!(element34 !in 1 .. 3) != range0.contains(element34)) throw AssertionError() -} - -fun testR0xE35() { - // with possible local optimizations - if (4.toDouble() in 1 .. 3 != range0.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in 1 .. 3 != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in 1 .. 3) != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in 1 .. 3) != range0.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in 1 .. 3 != range0.contains(element35)) throw AssertionError() - if (element35 !in 1 .. 3 != !range0.contains(element35)) throw AssertionError() - if (!(element35 in 1 .. 3) != !range0.contains(element35)) throw AssertionError() - if (!(element35 !in 1 .. 3) != range0.contains(element35)) throw AssertionError() + if (element23 in 1 .. 3 != range0.contains(element23)) throw AssertionError() + if (element23 !in 1 .. 3 != !range0.contains(element23)) throw AssertionError() + if (!(element23 in 1 .. 3) != !range0.contains(element23)) throw AssertionError() + if (!(element23 !in 1 .. 3) != range0.contains(element23)) throw AssertionError() } fun testR1xE0() { @@ -642,10 +450,10 @@ fun testR1xE3() { fun testR1xE4() { // with possible local optimizations - if ((-1).toFloat() in 3 .. 1 != range1.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in 3 .. 1 != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in 3 .. 1) != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in 3 .. 1) != range1.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in 3 .. 1 != range1.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in 3 .. 1 != !range1.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in 3 .. 1) != !range1.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in 3 .. 1) != range1.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in 3 .. 1 != range1.contains(element4)) throw AssertionError() if (element4 !in 3 .. 1 != !range1.contains(element4)) throw AssertionError() @@ -655,10 +463,10 @@ fun testR1xE4() { fun testR1xE5() { // with possible local optimizations - if ((-1).toDouble() in 3 .. 1 != range1.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in 3 .. 1 != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in 3 .. 1) != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in 3 .. 1) != range1.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in 3 .. 1 != range1.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in 3 .. 1 != !range1.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in 3 .. 1) != !range1.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in 3 .. 1) != range1.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in 3 .. 1 != range1.contains(element5)) throw AssertionError() if (element5 !in 3 .. 1 != !range1.contains(element5)) throw AssertionError() @@ -668,10 +476,10 @@ fun testR1xE5() { fun testR1xE6() { // with possible local optimizations - if (0.toByte() in 3 .. 1 != range1.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in 3 .. 1 != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in 3 .. 1) != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in 3 .. 1) != range1.contains(0.toByte())) throw AssertionError() + if (0 in 3 .. 1 != range1.contains(0)) throw AssertionError() + if (0 !in 3 .. 1 != !range1.contains(0)) throw AssertionError() + if (!(0 in 3 .. 1) != !range1.contains(0)) throw AssertionError() + if (!(0 !in 3 .. 1) != range1.contains(0)) throw AssertionError() // no local optimizations if (element6 in 3 .. 1 != range1.contains(element6)) throw AssertionError() if (element6 !in 3 .. 1 != !range1.contains(element6)) throw AssertionError() @@ -681,10 +489,10 @@ fun testR1xE6() { fun testR1xE7() { // with possible local optimizations - if (0.toShort() in 3 .. 1 != range1.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in 3 .. 1 != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in 3 .. 1) != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in 3 .. 1) != range1.contains(0.toShort())) throw AssertionError() + if (0.toLong() in 3 .. 1 != range1.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in 3 .. 1 != !range1.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in 3 .. 1) != !range1.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in 3 .. 1) != range1.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in 3 .. 1 != range1.contains(element7)) throw AssertionError() if (element7 !in 3 .. 1 != !range1.contains(element7)) throw AssertionError() @@ -694,10 +502,10 @@ fun testR1xE7() { fun testR1xE8() { // with possible local optimizations - if (0 in 3 .. 1 != range1.contains(0)) throw AssertionError() - if (0 !in 3 .. 1 != !range1.contains(0)) throw AssertionError() - if (!(0 in 3 .. 1) != !range1.contains(0)) throw AssertionError() - if (!(0 !in 3 .. 1) != range1.contains(0)) throw AssertionError() + if (1.toByte() in 3 .. 1 != range1.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in 3 .. 1 != !range1.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in 3 .. 1) != !range1.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in 3 .. 1) != range1.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in 3 .. 1 != range1.contains(element8)) throw AssertionError() if (element8 !in 3 .. 1 != !range1.contains(element8)) throw AssertionError() @@ -707,10 +515,10 @@ fun testR1xE8() { fun testR1xE9() { // with possible local optimizations - if (0.toLong() in 3 .. 1 != range1.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in 3 .. 1 != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in 3 .. 1) != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in 3 .. 1) != range1.contains(0.toLong())) throw AssertionError() + if (1.toShort() in 3 .. 1 != range1.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in 3 .. 1 != !range1.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in 3 .. 1) != !range1.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in 3 .. 1) != range1.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in 3 .. 1 != range1.contains(element9)) throw AssertionError() if (element9 !in 3 .. 1 != !range1.contains(element9)) throw AssertionError() @@ -720,10 +528,10 @@ fun testR1xE9() { fun testR1xE10() { // with possible local optimizations - if (0.toFloat() in 3 .. 1 != range1.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in 3 .. 1 != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in 3 .. 1) != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in 3 .. 1) != range1.contains(0.toFloat())) throw AssertionError() + if (1 in 3 .. 1 != range1.contains(1)) throw AssertionError() + if (1 !in 3 .. 1 != !range1.contains(1)) throw AssertionError() + if (!(1 in 3 .. 1) != !range1.contains(1)) throw AssertionError() + if (!(1 !in 3 .. 1) != range1.contains(1)) throw AssertionError() // no local optimizations if (element10 in 3 .. 1 != range1.contains(element10)) throw AssertionError() if (element10 !in 3 .. 1 != !range1.contains(element10)) throw AssertionError() @@ -733,10 +541,10 @@ fun testR1xE10() { fun testR1xE11() { // with possible local optimizations - if (0.toDouble() in 3 .. 1 != range1.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in 3 .. 1 != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in 3 .. 1) != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in 3 .. 1) != range1.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in 3 .. 1 != range1.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in 3 .. 1 != !range1.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in 3 .. 1) != !range1.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in 3 .. 1) != range1.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in 3 .. 1 != range1.contains(element11)) throw AssertionError() if (element11 !in 3 .. 1 != !range1.contains(element11)) throw AssertionError() @@ -746,10 +554,10 @@ fun testR1xE11() { fun testR1xE12() { // with possible local optimizations - if (1.toByte() in 3 .. 1 != range1.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in 3 .. 1 != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in 3 .. 1) != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in 3 .. 1) != range1.contains(1.toByte())) throw AssertionError() + if (2.toByte() in 3 .. 1 != range1.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in 3 .. 1 != !range1.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in 3 .. 1) != !range1.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in 3 .. 1) != range1.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in 3 .. 1 != range1.contains(element12)) throw AssertionError() if (element12 !in 3 .. 1 != !range1.contains(element12)) throw AssertionError() @@ -759,10 +567,10 @@ fun testR1xE12() { fun testR1xE13() { // with possible local optimizations - if (1.toShort() in 3 .. 1 != range1.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in 3 .. 1 != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in 3 .. 1) != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in 3 .. 1) != range1.contains(1.toShort())) throw AssertionError() + if (2.toShort() in 3 .. 1 != range1.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in 3 .. 1 != !range1.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in 3 .. 1) != !range1.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in 3 .. 1) != range1.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in 3 .. 1 != range1.contains(element13)) throw AssertionError() if (element13 !in 3 .. 1 != !range1.contains(element13)) throw AssertionError() @@ -772,10 +580,10 @@ fun testR1xE13() { fun testR1xE14() { // with possible local optimizations - if (1 in 3 .. 1 != range1.contains(1)) throw AssertionError() - if (1 !in 3 .. 1 != !range1.contains(1)) throw AssertionError() - if (!(1 in 3 .. 1) != !range1.contains(1)) throw AssertionError() - if (!(1 !in 3 .. 1) != range1.contains(1)) throw AssertionError() + if (2 in 3 .. 1 != range1.contains(2)) throw AssertionError() + if (2 !in 3 .. 1 != !range1.contains(2)) throw AssertionError() + if (!(2 in 3 .. 1) != !range1.contains(2)) throw AssertionError() + if (!(2 !in 3 .. 1) != range1.contains(2)) throw AssertionError() // no local optimizations if (element14 in 3 .. 1 != range1.contains(element14)) throw AssertionError() if (element14 !in 3 .. 1 != !range1.contains(element14)) throw AssertionError() @@ -785,10 +593,10 @@ fun testR1xE14() { fun testR1xE15() { // with possible local optimizations - if (1.toLong() in 3 .. 1 != range1.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in 3 .. 1 != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in 3 .. 1) != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in 3 .. 1) != range1.contains(1.toLong())) throw AssertionError() + if (2.toLong() in 3 .. 1 != range1.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in 3 .. 1 != !range1.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in 3 .. 1) != !range1.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in 3 .. 1) != range1.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in 3 .. 1 != range1.contains(element15)) throw AssertionError() if (element15 !in 3 .. 1 != !range1.contains(element15)) throw AssertionError() @@ -798,10 +606,10 @@ fun testR1xE15() { fun testR1xE16() { // with possible local optimizations - if (1.toFloat() in 3 .. 1 != range1.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in 3 .. 1 != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in 3 .. 1) != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in 3 .. 1) != range1.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in 3 .. 1 != range1.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in 3 .. 1 != !range1.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in 3 .. 1) != !range1.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in 3 .. 1) != range1.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in 3 .. 1 != range1.contains(element16)) throw AssertionError() if (element16 !in 3 .. 1 != !range1.contains(element16)) throw AssertionError() @@ -811,10 +619,10 @@ fun testR1xE16() { fun testR1xE17() { // with possible local optimizations - if (1.toDouble() in 3 .. 1 != range1.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in 3 .. 1 != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in 3 .. 1) != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in 3 .. 1) != range1.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in 3 .. 1 != range1.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in 3 .. 1 != !range1.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in 3 .. 1) != !range1.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in 3 .. 1) != range1.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in 3 .. 1 != range1.contains(element17)) throw AssertionError() if (element17 !in 3 .. 1 != !range1.contains(element17)) throw AssertionError() @@ -824,10 +632,10 @@ fun testR1xE17() { fun testR1xE18() { // with possible local optimizations - if (2.toByte() in 3 .. 1 != range1.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in 3 .. 1 != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in 3 .. 1) != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in 3 .. 1) != range1.contains(2.toByte())) throw AssertionError() + if (3 in 3 .. 1 != range1.contains(3)) throw AssertionError() + if (3 !in 3 .. 1 != !range1.contains(3)) throw AssertionError() + if (!(3 in 3 .. 1) != !range1.contains(3)) throw AssertionError() + if (!(3 !in 3 .. 1) != range1.contains(3)) throw AssertionError() // no local optimizations if (element18 in 3 .. 1 != range1.contains(element18)) throw AssertionError() if (element18 !in 3 .. 1 != !range1.contains(element18)) throw AssertionError() @@ -837,10 +645,10 @@ fun testR1xE18() { fun testR1xE19() { // with possible local optimizations - if (2.toShort() in 3 .. 1 != range1.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in 3 .. 1 != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in 3 .. 1) != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in 3 .. 1) != range1.contains(2.toShort())) throw AssertionError() + if (3.toLong() in 3 .. 1 != range1.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in 3 .. 1 != !range1.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in 3 .. 1) != !range1.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in 3 .. 1) != range1.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in 3 .. 1 != range1.contains(element19)) throw AssertionError() if (element19 !in 3 .. 1 != !range1.contains(element19)) throw AssertionError() @@ -850,10 +658,10 @@ fun testR1xE19() { fun testR1xE20() { // with possible local optimizations - if (2 in 3 .. 1 != range1.contains(2)) throw AssertionError() - if (2 !in 3 .. 1 != !range1.contains(2)) throw AssertionError() - if (!(2 in 3 .. 1) != !range1.contains(2)) throw AssertionError() - if (!(2 !in 3 .. 1) != range1.contains(2)) throw AssertionError() + if (4.toByte() in 3 .. 1 != range1.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in 3 .. 1 != !range1.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in 3 .. 1) != !range1.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in 3 .. 1) != range1.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in 3 .. 1 != range1.contains(element20)) throw AssertionError() if (element20 !in 3 .. 1 != !range1.contains(element20)) throw AssertionError() @@ -863,10 +671,10 @@ fun testR1xE20() { fun testR1xE21() { // with possible local optimizations - if (2.toLong() in 3 .. 1 != range1.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in 3 .. 1 != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in 3 .. 1) != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in 3 .. 1) != range1.contains(2.toLong())) throw AssertionError() + if (4.toShort() in 3 .. 1 != range1.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in 3 .. 1 != !range1.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in 3 .. 1) != !range1.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in 3 .. 1) != range1.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in 3 .. 1 != range1.contains(element21)) throw AssertionError() if (element21 !in 3 .. 1 != !range1.contains(element21)) throw AssertionError() @@ -876,10 +684,10 @@ fun testR1xE21() { fun testR1xE22() { // with possible local optimizations - if (2.toFloat() in 3 .. 1 != range1.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in 3 .. 1 != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in 3 .. 1) != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in 3 .. 1) != range1.contains(2.toFloat())) throw AssertionError() + if (4 in 3 .. 1 != range1.contains(4)) throw AssertionError() + if (4 !in 3 .. 1 != !range1.contains(4)) throw AssertionError() + if (!(4 in 3 .. 1) != !range1.contains(4)) throw AssertionError() + if (!(4 !in 3 .. 1) != range1.contains(4)) throw AssertionError() // no local optimizations if (element22 in 3 .. 1 != range1.contains(element22)) throw AssertionError() if (element22 !in 3 .. 1 != !range1.contains(element22)) throw AssertionError() @@ -889,10 +697,10 @@ fun testR1xE22() { fun testR1xE23() { // with possible local optimizations - if (2.toDouble() in 3 .. 1 != range1.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in 3 .. 1 != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in 3 .. 1) != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in 3 .. 1) != range1.contains(2.toDouble())) throw AssertionError() + if (4.toLong() in 3 .. 1 != range1.contains(4.toLong())) throw AssertionError() + if (4.toLong() !in 3 .. 1 != !range1.contains(4.toLong())) throw AssertionError() + if (!(4.toLong() in 3 .. 1) != !range1.contains(4.toLong())) throw AssertionError() + if (!(4.toLong() !in 3 .. 1) != range1.contains(4.toLong())) throw AssertionError() // no local optimizations if (element23 in 3 .. 1 != range1.contains(element23)) throw AssertionError() if (element23 !in 3 .. 1 != !range1.contains(element23)) throw AssertionError() @@ -900,160 +708,4 @@ fun testR1xE23() { if (!(element23 !in 3 .. 1) != range1.contains(element23)) throw AssertionError() } -fun testR1xE24() { - // with possible local optimizations - if (3.toByte() in 3 .. 1 != range1.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in 3 .. 1 != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in 3 .. 1) != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in 3 .. 1) != range1.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in 3 .. 1 != range1.contains(element24)) throw AssertionError() - if (element24 !in 3 .. 1 != !range1.contains(element24)) throw AssertionError() - if (!(element24 in 3 .. 1) != !range1.contains(element24)) throw AssertionError() - if (!(element24 !in 3 .. 1) != range1.contains(element24)) throw AssertionError() -} - -fun testR1xE25() { - // with possible local optimizations - if (3.toShort() in 3 .. 1 != range1.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in 3 .. 1 != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in 3 .. 1) != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in 3 .. 1) != range1.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in 3 .. 1 != range1.contains(element25)) throw AssertionError() - if (element25 !in 3 .. 1 != !range1.contains(element25)) throw AssertionError() - if (!(element25 in 3 .. 1) != !range1.contains(element25)) throw AssertionError() - if (!(element25 !in 3 .. 1) != range1.contains(element25)) throw AssertionError() -} - -fun testR1xE26() { - // with possible local optimizations - if (3 in 3 .. 1 != range1.contains(3)) throw AssertionError() - if (3 !in 3 .. 1 != !range1.contains(3)) throw AssertionError() - if (!(3 in 3 .. 1) != !range1.contains(3)) throw AssertionError() - if (!(3 !in 3 .. 1) != range1.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in 3 .. 1 != range1.contains(element26)) throw AssertionError() - if (element26 !in 3 .. 1 != !range1.contains(element26)) throw AssertionError() - if (!(element26 in 3 .. 1) != !range1.contains(element26)) throw AssertionError() - if (!(element26 !in 3 .. 1) != range1.contains(element26)) throw AssertionError() -} - -fun testR1xE27() { - // with possible local optimizations - if (3.toLong() in 3 .. 1 != range1.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in 3 .. 1 != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in 3 .. 1) != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in 3 .. 1) != range1.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in 3 .. 1 != range1.contains(element27)) throw AssertionError() - if (element27 !in 3 .. 1 != !range1.contains(element27)) throw AssertionError() - if (!(element27 in 3 .. 1) != !range1.contains(element27)) throw AssertionError() - if (!(element27 !in 3 .. 1) != range1.contains(element27)) throw AssertionError() -} - -fun testR1xE28() { - // with possible local optimizations - if (3.toFloat() in 3 .. 1 != range1.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in 3 .. 1 != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in 3 .. 1) != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in 3 .. 1) != range1.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in 3 .. 1 != range1.contains(element28)) throw AssertionError() - if (element28 !in 3 .. 1 != !range1.contains(element28)) throw AssertionError() - if (!(element28 in 3 .. 1) != !range1.contains(element28)) throw AssertionError() - if (!(element28 !in 3 .. 1) != range1.contains(element28)) throw AssertionError() -} - -fun testR1xE29() { - // with possible local optimizations - if (3.toDouble() in 3 .. 1 != range1.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in 3 .. 1 != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in 3 .. 1) != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in 3 .. 1) != range1.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in 3 .. 1 != range1.contains(element29)) throw AssertionError() - if (element29 !in 3 .. 1 != !range1.contains(element29)) throw AssertionError() - if (!(element29 in 3 .. 1) != !range1.contains(element29)) throw AssertionError() - if (!(element29 !in 3 .. 1) != range1.contains(element29)) throw AssertionError() -} - -fun testR1xE30() { - // with possible local optimizations - if (4.toByte() in 3 .. 1 != range1.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in 3 .. 1 != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in 3 .. 1) != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in 3 .. 1) != range1.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in 3 .. 1 != range1.contains(element30)) throw AssertionError() - if (element30 !in 3 .. 1 != !range1.contains(element30)) throw AssertionError() - if (!(element30 in 3 .. 1) != !range1.contains(element30)) throw AssertionError() - if (!(element30 !in 3 .. 1) != range1.contains(element30)) throw AssertionError() -} - -fun testR1xE31() { - // with possible local optimizations - if (4.toShort() in 3 .. 1 != range1.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in 3 .. 1 != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in 3 .. 1) != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in 3 .. 1) != range1.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in 3 .. 1 != range1.contains(element31)) throw AssertionError() - if (element31 !in 3 .. 1 != !range1.contains(element31)) throw AssertionError() - if (!(element31 in 3 .. 1) != !range1.contains(element31)) throw AssertionError() - if (!(element31 !in 3 .. 1) != range1.contains(element31)) throw AssertionError() -} - -fun testR1xE32() { - // with possible local optimizations - if (4 in 3 .. 1 != range1.contains(4)) throw AssertionError() - if (4 !in 3 .. 1 != !range1.contains(4)) throw AssertionError() - if (!(4 in 3 .. 1) != !range1.contains(4)) throw AssertionError() - if (!(4 !in 3 .. 1) != range1.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in 3 .. 1 != range1.contains(element32)) throw AssertionError() - if (element32 !in 3 .. 1 != !range1.contains(element32)) throw AssertionError() - if (!(element32 in 3 .. 1) != !range1.contains(element32)) throw AssertionError() - if (!(element32 !in 3 .. 1) != range1.contains(element32)) throw AssertionError() -} - -fun testR1xE33() { - // with possible local optimizations - if (4.toLong() in 3 .. 1 != range1.contains(4.toLong())) throw AssertionError() - if (4.toLong() !in 3 .. 1 != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() in 3 .. 1) != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() !in 3 .. 1) != range1.contains(4.toLong())) throw AssertionError() - // no local optimizations - if (element33 in 3 .. 1 != range1.contains(element33)) throw AssertionError() - if (element33 !in 3 .. 1 != !range1.contains(element33)) throw AssertionError() - if (!(element33 in 3 .. 1) != !range1.contains(element33)) throw AssertionError() - if (!(element33 !in 3 .. 1) != range1.contains(element33)) throw AssertionError() -} - -fun testR1xE34() { - // with possible local optimizations - if (4.toFloat() in 3 .. 1 != range1.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in 3 .. 1 != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in 3 .. 1) != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in 3 .. 1) != range1.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in 3 .. 1 != range1.contains(element34)) throw AssertionError() - if (element34 !in 3 .. 1 != !range1.contains(element34)) throw AssertionError() - if (!(element34 in 3 .. 1) != !range1.contains(element34)) throw AssertionError() - if (!(element34 !in 3 .. 1) != range1.contains(element34)) throw AssertionError() -} - -fun testR1xE35() { - // with possible local optimizations - if (4.toDouble() in 3 .. 1 != range1.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in 3 .. 1 != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in 3 .. 1) != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in 3 .. 1) != range1.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in 3 .. 1 != range1.contains(element35)) throw AssertionError() - if (element35 !in 3 .. 1 != !range1.contains(element35)) throw AssertionError() - if (!(element35 in 3 .. 1) != !range1.contains(element35)) throw AssertionError() - if (!(element35 !in 3 .. 1) != range1.contains(element35)) throw AssertionError() -} - diff --git a/compiler/testData/codegen/box/ranges/contains/generated/intUntil.kt b/compiler/testData/codegen/box/ranges/contains/generated/intUntil.kt index 79e71daba97..780a79cc611 100644 --- a/compiler/testData/codegen/box/ranges/contains/generated/intUntil.kt +++ b/compiler/testData/codegen/box/ranges/contains/generated/intUntil.kt @@ -11,38 +11,26 @@ val element0 = (-1).toByte() val element1 = (-1).toShort() val element2 = (-1) val element3 = (-1).toLong() -val element4 = (-1).toFloat() -val element5 = (-1).toDouble() -val element6 = 0.toByte() -val element7 = 0.toShort() -val element8 = 0 -val element9 = 0.toLong() -val element10 = 0.toFloat() -val element11 = 0.toDouble() -val element12 = 1.toByte() -val element13 = 1.toShort() -val element14 = 1 -val element15 = 1.toLong() -val element16 = 1.toFloat() -val element17 = 1.toDouble() -val element18 = 2.toByte() -val element19 = 2.toShort() -val element20 = 2 -val element21 = 2.toLong() -val element22 = 2.toFloat() -val element23 = 2.toDouble() -val element24 = 3.toByte() -val element25 = 3.toShort() -val element26 = 3 -val element27 = 3.toLong() -val element28 = 3.toFloat() -val element29 = 3.toDouble() -val element30 = 4.toByte() -val element31 = 4.toShort() -val element32 = 4 -val element33 = 4.toLong() -val element34 = 4.toFloat() -val element35 = 4.toDouble() +val element4 = 0.toByte() +val element5 = 0.toShort() +val element6 = 0 +val element7 = 0.toLong() +val element8 = 1.toByte() +val element9 = 1.toShort() +val element10 = 1 +val element11 = 1.toLong() +val element12 = 2.toByte() +val element13 = 2.toShort() +val element14 = 2 +val element15 = 2.toLong() +val element16 = 3.toByte() +val element17 = 3.toShort() +val element18 = 3 +val element19 = 3.toLong() +val element20 = 4.toByte() +val element21 = 4.toShort() +val element22 = 4 +val element23 = 4.toLong() fun box(): String { testR0xE0() @@ -69,18 +57,6 @@ fun box(): String { testR0xE21() testR0xE22() testR0xE23() - testR0xE24() - testR0xE25() - testR0xE26() - testR0xE27() - testR0xE28() - testR0xE29() - testR0xE30() - testR0xE31() - testR0xE32() - testR0xE33() - testR0xE34() - testR0xE35() testR1xE0() testR1xE1() testR1xE2() @@ -105,18 +81,6 @@ fun box(): String { testR1xE21() testR1xE22() testR1xE23() - testR1xE24() - testR1xE25() - testR1xE26() - testR1xE27() - testR1xE28() - testR1xE29() - testR1xE30() - testR1xE31() - testR1xE32() - testR1xE33() - testR1xE34() - testR1xE35() return "OK" } @@ -174,10 +138,10 @@ fun testR0xE3() { fun testR0xE4() { // with possible local optimizations - if ((-1).toFloat() in 1 until 3 != range0.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in 1 until 3 != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in 1 until 3) != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in 1 until 3) != range0.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in 1 until 3 != range0.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in 1 until 3 != !range0.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in 1 until 3) != !range0.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in 1 until 3) != range0.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in 1 until 3 != range0.contains(element4)) throw AssertionError() if (element4 !in 1 until 3 != !range0.contains(element4)) throw AssertionError() @@ -187,10 +151,10 @@ fun testR0xE4() { fun testR0xE5() { // with possible local optimizations - if ((-1).toDouble() in 1 until 3 != range0.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in 1 until 3 != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in 1 until 3) != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in 1 until 3) != range0.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in 1 until 3 != range0.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in 1 until 3 != !range0.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in 1 until 3) != !range0.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in 1 until 3) != range0.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in 1 until 3 != range0.contains(element5)) throw AssertionError() if (element5 !in 1 until 3 != !range0.contains(element5)) throw AssertionError() @@ -200,10 +164,10 @@ fun testR0xE5() { fun testR0xE6() { // with possible local optimizations - if (0.toByte() in 1 until 3 != range0.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in 1 until 3 != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in 1 until 3) != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in 1 until 3) != range0.contains(0.toByte())) throw AssertionError() + if (0 in 1 until 3 != range0.contains(0)) throw AssertionError() + if (0 !in 1 until 3 != !range0.contains(0)) throw AssertionError() + if (!(0 in 1 until 3) != !range0.contains(0)) throw AssertionError() + if (!(0 !in 1 until 3) != range0.contains(0)) throw AssertionError() // no local optimizations if (element6 in 1 until 3 != range0.contains(element6)) throw AssertionError() if (element6 !in 1 until 3 != !range0.contains(element6)) throw AssertionError() @@ -213,10 +177,10 @@ fun testR0xE6() { fun testR0xE7() { // with possible local optimizations - if (0.toShort() in 1 until 3 != range0.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in 1 until 3 != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in 1 until 3) != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in 1 until 3) != range0.contains(0.toShort())) throw AssertionError() + if (0.toLong() in 1 until 3 != range0.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in 1 until 3 != !range0.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in 1 until 3) != !range0.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in 1 until 3) != range0.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in 1 until 3 != range0.contains(element7)) throw AssertionError() if (element7 !in 1 until 3 != !range0.contains(element7)) throw AssertionError() @@ -226,10 +190,10 @@ fun testR0xE7() { fun testR0xE8() { // with possible local optimizations - if (0 in 1 until 3 != range0.contains(0)) throw AssertionError() - if (0 !in 1 until 3 != !range0.contains(0)) throw AssertionError() - if (!(0 in 1 until 3) != !range0.contains(0)) throw AssertionError() - if (!(0 !in 1 until 3) != range0.contains(0)) throw AssertionError() + if (1.toByte() in 1 until 3 != range0.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in 1 until 3 != !range0.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in 1 until 3) != !range0.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in 1 until 3) != range0.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in 1 until 3 != range0.contains(element8)) throw AssertionError() if (element8 !in 1 until 3 != !range0.contains(element8)) throw AssertionError() @@ -239,10 +203,10 @@ fun testR0xE8() { fun testR0xE9() { // with possible local optimizations - if (0.toLong() in 1 until 3 != range0.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in 1 until 3 != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in 1 until 3) != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in 1 until 3) != range0.contains(0.toLong())) throw AssertionError() + if (1.toShort() in 1 until 3 != range0.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in 1 until 3 != !range0.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in 1 until 3) != !range0.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in 1 until 3) != range0.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in 1 until 3 != range0.contains(element9)) throw AssertionError() if (element9 !in 1 until 3 != !range0.contains(element9)) throw AssertionError() @@ -252,10 +216,10 @@ fun testR0xE9() { fun testR0xE10() { // with possible local optimizations - if (0.toFloat() in 1 until 3 != range0.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in 1 until 3 != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in 1 until 3) != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in 1 until 3) != range0.contains(0.toFloat())) throw AssertionError() + if (1 in 1 until 3 != range0.contains(1)) throw AssertionError() + if (1 !in 1 until 3 != !range0.contains(1)) throw AssertionError() + if (!(1 in 1 until 3) != !range0.contains(1)) throw AssertionError() + if (!(1 !in 1 until 3) != range0.contains(1)) throw AssertionError() // no local optimizations if (element10 in 1 until 3 != range0.contains(element10)) throw AssertionError() if (element10 !in 1 until 3 != !range0.contains(element10)) throw AssertionError() @@ -265,10 +229,10 @@ fun testR0xE10() { fun testR0xE11() { // with possible local optimizations - if (0.toDouble() in 1 until 3 != range0.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in 1 until 3 != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in 1 until 3) != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in 1 until 3) != range0.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in 1 until 3 != range0.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in 1 until 3 != !range0.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in 1 until 3) != !range0.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in 1 until 3) != range0.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in 1 until 3 != range0.contains(element11)) throw AssertionError() if (element11 !in 1 until 3 != !range0.contains(element11)) throw AssertionError() @@ -278,10 +242,10 @@ fun testR0xE11() { fun testR0xE12() { // with possible local optimizations - if (1.toByte() in 1 until 3 != range0.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in 1 until 3 != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in 1 until 3) != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in 1 until 3) != range0.contains(1.toByte())) throw AssertionError() + if (2.toByte() in 1 until 3 != range0.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in 1 until 3 != !range0.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in 1 until 3) != !range0.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in 1 until 3) != range0.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in 1 until 3 != range0.contains(element12)) throw AssertionError() if (element12 !in 1 until 3 != !range0.contains(element12)) throw AssertionError() @@ -291,10 +255,10 @@ fun testR0xE12() { fun testR0xE13() { // with possible local optimizations - if (1.toShort() in 1 until 3 != range0.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in 1 until 3 != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in 1 until 3) != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in 1 until 3) != range0.contains(1.toShort())) throw AssertionError() + if (2.toShort() in 1 until 3 != range0.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in 1 until 3 != !range0.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in 1 until 3) != !range0.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in 1 until 3) != range0.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in 1 until 3 != range0.contains(element13)) throw AssertionError() if (element13 !in 1 until 3 != !range0.contains(element13)) throw AssertionError() @@ -304,10 +268,10 @@ fun testR0xE13() { fun testR0xE14() { // with possible local optimizations - if (1 in 1 until 3 != range0.contains(1)) throw AssertionError() - if (1 !in 1 until 3 != !range0.contains(1)) throw AssertionError() - if (!(1 in 1 until 3) != !range0.contains(1)) throw AssertionError() - if (!(1 !in 1 until 3) != range0.contains(1)) throw AssertionError() + if (2 in 1 until 3 != range0.contains(2)) throw AssertionError() + if (2 !in 1 until 3 != !range0.contains(2)) throw AssertionError() + if (!(2 in 1 until 3) != !range0.contains(2)) throw AssertionError() + if (!(2 !in 1 until 3) != range0.contains(2)) throw AssertionError() // no local optimizations if (element14 in 1 until 3 != range0.contains(element14)) throw AssertionError() if (element14 !in 1 until 3 != !range0.contains(element14)) throw AssertionError() @@ -317,10 +281,10 @@ fun testR0xE14() { fun testR0xE15() { // with possible local optimizations - if (1.toLong() in 1 until 3 != range0.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in 1 until 3 != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in 1 until 3) != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in 1 until 3) != range0.contains(1.toLong())) throw AssertionError() + if (2.toLong() in 1 until 3 != range0.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in 1 until 3 != !range0.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in 1 until 3) != !range0.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in 1 until 3) != range0.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in 1 until 3 != range0.contains(element15)) throw AssertionError() if (element15 !in 1 until 3 != !range0.contains(element15)) throw AssertionError() @@ -330,10 +294,10 @@ fun testR0xE15() { fun testR0xE16() { // with possible local optimizations - if (1.toFloat() in 1 until 3 != range0.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in 1 until 3 != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in 1 until 3) != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in 1 until 3) != range0.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in 1 until 3 != range0.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in 1 until 3 != !range0.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in 1 until 3) != !range0.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in 1 until 3) != range0.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in 1 until 3 != range0.contains(element16)) throw AssertionError() if (element16 !in 1 until 3 != !range0.contains(element16)) throw AssertionError() @@ -343,10 +307,10 @@ fun testR0xE16() { fun testR0xE17() { // with possible local optimizations - if (1.toDouble() in 1 until 3 != range0.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in 1 until 3 != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in 1 until 3) != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in 1 until 3) != range0.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in 1 until 3 != range0.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in 1 until 3 != !range0.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in 1 until 3) != !range0.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in 1 until 3) != range0.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in 1 until 3 != range0.contains(element17)) throw AssertionError() if (element17 !in 1 until 3 != !range0.contains(element17)) throw AssertionError() @@ -356,10 +320,10 @@ fun testR0xE17() { fun testR0xE18() { // with possible local optimizations - if (2.toByte() in 1 until 3 != range0.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in 1 until 3 != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in 1 until 3) != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in 1 until 3) != range0.contains(2.toByte())) throw AssertionError() + if (3 in 1 until 3 != range0.contains(3)) throw AssertionError() + if (3 !in 1 until 3 != !range0.contains(3)) throw AssertionError() + if (!(3 in 1 until 3) != !range0.contains(3)) throw AssertionError() + if (!(3 !in 1 until 3) != range0.contains(3)) throw AssertionError() // no local optimizations if (element18 in 1 until 3 != range0.contains(element18)) throw AssertionError() if (element18 !in 1 until 3 != !range0.contains(element18)) throw AssertionError() @@ -369,10 +333,10 @@ fun testR0xE18() { fun testR0xE19() { // with possible local optimizations - if (2.toShort() in 1 until 3 != range0.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in 1 until 3 != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in 1 until 3) != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in 1 until 3) != range0.contains(2.toShort())) throw AssertionError() + if (3.toLong() in 1 until 3 != range0.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in 1 until 3 != !range0.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in 1 until 3) != !range0.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in 1 until 3) != range0.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in 1 until 3 != range0.contains(element19)) throw AssertionError() if (element19 !in 1 until 3 != !range0.contains(element19)) throw AssertionError() @@ -382,10 +346,10 @@ fun testR0xE19() { fun testR0xE20() { // with possible local optimizations - if (2 in 1 until 3 != range0.contains(2)) throw AssertionError() - if (2 !in 1 until 3 != !range0.contains(2)) throw AssertionError() - if (!(2 in 1 until 3) != !range0.contains(2)) throw AssertionError() - if (!(2 !in 1 until 3) != range0.contains(2)) throw AssertionError() + if (4.toByte() in 1 until 3 != range0.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in 1 until 3 != !range0.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in 1 until 3) != !range0.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in 1 until 3) != range0.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in 1 until 3 != range0.contains(element20)) throw AssertionError() if (element20 !in 1 until 3 != !range0.contains(element20)) throw AssertionError() @@ -395,10 +359,10 @@ fun testR0xE20() { fun testR0xE21() { // with possible local optimizations - if (2.toLong() in 1 until 3 != range0.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in 1 until 3 != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in 1 until 3) != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in 1 until 3) != range0.contains(2.toLong())) throw AssertionError() + if (4.toShort() in 1 until 3 != range0.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in 1 until 3 != !range0.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in 1 until 3) != !range0.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in 1 until 3) != range0.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in 1 until 3 != range0.contains(element21)) throw AssertionError() if (element21 !in 1 until 3 != !range0.contains(element21)) throw AssertionError() @@ -408,10 +372,10 @@ fun testR0xE21() { fun testR0xE22() { // with possible local optimizations - if (2.toFloat() in 1 until 3 != range0.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in 1 until 3 != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in 1 until 3) != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in 1 until 3) != range0.contains(2.toFloat())) throw AssertionError() + if (4 in 1 until 3 != range0.contains(4)) throw AssertionError() + if (4 !in 1 until 3 != !range0.contains(4)) throw AssertionError() + if (!(4 in 1 until 3) != !range0.contains(4)) throw AssertionError() + if (!(4 !in 1 until 3) != range0.contains(4)) throw AssertionError() // no local optimizations if (element22 in 1 until 3 != range0.contains(element22)) throw AssertionError() if (element22 !in 1 until 3 != !range0.contains(element22)) throw AssertionError() @@ -420,172 +384,16 @@ fun testR0xE22() { } fun testR0xE23() { - // with possible local optimizations - if (2.toDouble() in 1 until 3 != range0.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in 1 until 3 != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in 1 until 3) != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in 1 until 3) != range0.contains(2.toDouble())) throw AssertionError() - // no local optimizations - if (element23 in 1 until 3 != range0.contains(element23)) throw AssertionError() - if (element23 !in 1 until 3 != !range0.contains(element23)) throw AssertionError() - if (!(element23 in 1 until 3) != !range0.contains(element23)) throw AssertionError() - if (!(element23 !in 1 until 3) != range0.contains(element23)) throw AssertionError() -} - -fun testR0xE24() { - // with possible local optimizations - if (3.toByte() in 1 until 3 != range0.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in 1 until 3 != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in 1 until 3) != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in 1 until 3) != range0.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in 1 until 3 != range0.contains(element24)) throw AssertionError() - if (element24 !in 1 until 3 != !range0.contains(element24)) throw AssertionError() - if (!(element24 in 1 until 3) != !range0.contains(element24)) throw AssertionError() - if (!(element24 !in 1 until 3) != range0.contains(element24)) throw AssertionError() -} - -fun testR0xE25() { - // with possible local optimizations - if (3.toShort() in 1 until 3 != range0.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in 1 until 3 != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in 1 until 3) != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in 1 until 3) != range0.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in 1 until 3 != range0.contains(element25)) throw AssertionError() - if (element25 !in 1 until 3 != !range0.contains(element25)) throw AssertionError() - if (!(element25 in 1 until 3) != !range0.contains(element25)) throw AssertionError() - if (!(element25 !in 1 until 3) != range0.contains(element25)) throw AssertionError() -} - -fun testR0xE26() { - // with possible local optimizations - if (3 in 1 until 3 != range0.contains(3)) throw AssertionError() - if (3 !in 1 until 3 != !range0.contains(3)) throw AssertionError() - if (!(3 in 1 until 3) != !range0.contains(3)) throw AssertionError() - if (!(3 !in 1 until 3) != range0.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in 1 until 3 != range0.contains(element26)) throw AssertionError() - if (element26 !in 1 until 3 != !range0.contains(element26)) throw AssertionError() - if (!(element26 in 1 until 3) != !range0.contains(element26)) throw AssertionError() - if (!(element26 !in 1 until 3) != range0.contains(element26)) throw AssertionError() -} - -fun testR0xE27() { - // with possible local optimizations - if (3.toLong() in 1 until 3 != range0.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in 1 until 3 != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in 1 until 3) != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in 1 until 3) != range0.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in 1 until 3 != range0.contains(element27)) throw AssertionError() - if (element27 !in 1 until 3 != !range0.contains(element27)) throw AssertionError() - if (!(element27 in 1 until 3) != !range0.contains(element27)) throw AssertionError() - if (!(element27 !in 1 until 3) != range0.contains(element27)) throw AssertionError() -} - -fun testR0xE28() { - // with possible local optimizations - if (3.toFloat() in 1 until 3 != range0.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in 1 until 3 != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in 1 until 3) != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in 1 until 3) != range0.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in 1 until 3 != range0.contains(element28)) throw AssertionError() - if (element28 !in 1 until 3 != !range0.contains(element28)) throw AssertionError() - if (!(element28 in 1 until 3) != !range0.contains(element28)) throw AssertionError() - if (!(element28 !in 1 until 3) != range0.contains(element28)) throw AssertionError() -} - -fun testR0xE29() { - // with possible local optimizations - if (3.toDouble() in 1 until 3 != range0.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in 1 until 3 != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in 1 until 3) != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in 1 until 3) != range0.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in 1 until 3 != range0.contains(element29)) throw AssertionError() - if (element29 !in 1 until 3 != !range0.contains(element29)) throw AssertionError() - if (!(element29 in 1 until 3) != !range0.contains(element29)) throw AssertionError() - if (!(element29 !in 1 until 3) != range0.contains(element29)) throw AssertionError() -} - -fun testR0xE30() { - // with possible local optimizations - if (4.toByte() in 1 until 3 != range0.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in 1 until 3 != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in 1 until 3) != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in 1 until 3) != range0.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in 1 until 3 != range0.contains(element30)) throw AssertionError() - if (element30 !in 1 until 3 != !range0.contains(element30)) throw AssertionError() - if (!(element30 in 1 until 3) != !range0.contains(element30)) throw AssertionError() - if (!(element30 !in 1 until 3) != range0.contains(element30)) throw AssertionError() -} - -fun testR0xE31() { - // with possible local optimizations - if (4.toShort() in 1 until 3 != range0.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in 1 until 3 != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in 1 until 3) != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in 1 until 3) != range0.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in 1 until 3 != range0.contains(element31)) throw AssertionError() - if (element31 !in 1 until 3 != !range0.contains(element31)) throw AssertionError() - if (!(element31 in 1 until 3) != !range0.contains(element31)) throw AssertionError() - if (!(element31 !in 1 until 3) != range0.contains(element31)) throw AssertionError() -} - -fun testR0xE32() { - // with possible local optimizations - if (4 in 1 until 3 != range0.contains(4)) throw AssertionError() - if (4 !in 1 until 3 != !range0.contains(4)) throw AssertionError() - if (!(4 in 1 until 3) != !range0.contains(4)) throw AssertionError() - if (!(4 !in 1 until 3) != range0.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in 1 until 3 != range0.contains(element32)) throw AssertionError() - if (element32 !in 1 until 3 != !range0.contains(element32)) throw AssertionError() - if (!(element32 in 1 until 3) != !range0.contains(element32)) throw AssertionError() - if (!(element32 !in 1 until 3) != range0.contains(element32)) throw AssertionError() -} - -fun testR0xE33() { // with possible local optimizations if (4.toLong() in 1 until 3 != range0.contains(4.toLong())) throw AssertionError() if (4.toLong() !in 1 until 3 != !range0.contains(4.toLong())) throw AssertionError() if (!(4.toLong() in 1 until 3) != !range0.contains(4.toLong())) throw AssertionError() if (!(4.toLong() !in 1 until 3) != range0.contains(4.toLong())) throw AssertionError() // no local optimizations - if (element33 in 1 until 3 != range0.contains(element33)) throw AssertionError() - if (element33 !in 1 until 3 != !range0.contains(element33)) throw AssertionError() - if (!(element33 in 1 until 3) != !range0.contains(element33)) throw AssertionError() - if (!(element33 !in 1 until 3) != range0.contains(element33)) throw AssertionError() -} - -fun testR0xE34() { - // with possible local optimizations - if (4.toFloat() in 1 until 3 != range0.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in 1 until 3 != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in 1 until 3) != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in 1 until 3) != range0.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in 1 until 3 != range0.contains(element34)) throw AssertionError() - if (element34 !in 1 until 3 != !range0.contains(element34)) throw AssertionError() - if (!(element34 in 1 until 3) != !range0.contains(element34)) throw AssertionError() - if (!(element34 !in 1 until 3) != range0.contains(element34)) throw AssertionError() -} - -fun testR0xE35() { - // with possible local optimizations - if (4.toDouble() in 1 until 3 != range0.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in 1 until 3 != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in 1 until 3) != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in 1 until 3) != range0.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in 1 until 3 != range0.contains(element35)) throw AssertionError() - if (element35 !in 1 until 3 != !range0.contains(element35)) throw AssertionError() - if (!(element35 in 1 until 3) != !range0.contains(element35)) throw AssertionError() - if (!(element35 !in 1 until 3) != range0.contains(element35)) throw AssertionError() + if (element23 in 1 until 3 != range0.contains(element23)) throw AssertionError() + if (element23 !in 1 until 3 != !range0.contains(element23)) throw AssertionError() + if (!(element23 in 1 until 3) != !range0.contains(element23)) throw AssertionError() + if (!(element23 !in 1 until 3) != range0.contains(element23)) throw AssertionError() } fun testR1xE0() { @@ -642,10 +450,10 @@ fun testR1xE3() { fun testR1xE4() { // with possible local optimizations - if ((-1).toFloat() in 3 until 1 != range1.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in 3 until 1 != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in 3 until 1) != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in 3 until 1) != range1.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in 3 until 1 != range1.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in 3 until 1 != !range1.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in 3 until 1) != !range1.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in 3 until 1) != range1.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in 3 until 1 != range1.contains(element4)) throw AssertionError() if (element4 !in 3 until 1 != !range1.contains(element4)) throw AssertionError() @@ -655,10 +463,10 @@ fun testR1xE4() { fun testR1xE5() { // with possible local optimizations - if ((-1).toDouble() in 3 until 1 != range1.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in 3 until 1 != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in 3 until 1) != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in 3 until 1) != range1.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in 3 until 1 != range1.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in 3 until 1 != !range1.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in 3 until 1) != !range1.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in 3 until 1) != range1.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in 3 until 1 != range1.contains(element5)) throw AssertionError() if (element5 !in 3 until 1 != !range1.contains(element5)) throw AssertionError() @@ -668,10 +476,10 @@ fun testR1xE5() { fun testR1xE6() { // with possible local optimizations - if (0.toByte() in 3 until 1 != range1.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in 3 until 1 != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in 3 until 1) != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in 3 until 1) != range1.contains(0.toByte())) throw AssertionError() + if (0 in 3 until 1 != range1.contains(0)) throw AssertionError() + if (0 !in 3 until 1 != !range1.contains(0)) throw AssertionError() + if (!(0 in 3 until 1) != !range1.contains(0)) throw AssertionError() + if (!(0 !in 3 until 1) != range1.contains(0)) throw AssertionError() // no local optimizations if (element6 in 3 until 1 != range1.contains(element6)) throw AssertionError() if (element6 !in 3 until 1 != !range1.contains(element6)) throw AssertionError() @@ -681,10 +489,10 @@ fun testR1xE6() { fun testR1xE7() { // with possible local optimizations - if (0.toShort() in 3 until 1 != range1.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in 3 until 1 != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in 3 until 1) != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in 3 until 1) != range1.contains(0.toShort())) throw AssertionError() + if (0.toLong() in 3 until 1 != range1.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in 3 until 1 != !range1.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in 3 until 1) != !range1.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in 3 until 1) != range1.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in 3 until 1 != range1.contains(element7)) throw AssertionError() if (element7 !in 3 until 1 != !range1.contains(element7)) throw AssertionError() @@ -694,10 +502,10 @@ fun testR1xE7() { fun testR1xE8() { // with possible local optimizations - if (0 in 3 until 1 != range1.contains(0)) throw AssertionError() - if (0 !in 3 until 1 != !range1.contains(0)) throw AssertionError() - if (!(0 in 3 until 1) != !range1.contains(0)) throw AssertionError() - if (!(0 !in 3 until 1) != range1.contains(0)) throw AssertionError() + if (1.toByte() in 3 until 1 != range1.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in 3 until 1 != !range1.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in 3 until 1) != !range1.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in 3 until 1) != range1.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in 3 until 1 != range1.contains(element8)) throw AssertionError() if (element8 !in 3 until 1 != !range1.contains(element8)) throw AssertionError() @@ -707,10 +515,10 @@ fun testR1xE8() { fun testR1xE9() { // with possible local optimizations - if (0.toLong() in 3 until 1 != range1.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in 3 until 1 != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in 3 until 1) != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in 3 until 1) != range1.contains(0.toLong())) throw AssertionError() + if (1.toShort() in 3 until 1 != range1.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in 3 until 1 != !range1.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in 3 until 1) != !range1.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in 3 until 1) != range1.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in 3 until 1 != range1.contains(element9)) throw AssertionError() if (element9 !in 3 until 1 != !range1.contains(element9)) throw AssertionError() @@ -720,10 +528,10 @@ fun testR1xE9() { fun testR1xE10() { // with possible local optimizations - if (0.toFloat() in 3 until 1 != range1.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in 3 until 1 != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in 3 until 1) != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in 3 until 1) != range1.contains(0.toFloat())) throw AssertionError() + if (1 in 3 until 1 != range1.contains(1)) throw AssertionError() + if (1 !in 3 until 1 != !range1.contains(1)) throw AssertionError() + if (!(1 in 3 until 1) != !range1.contains(1)) throw AssertionError() + if (!(1 !in 3 until 1) != range1.contains(1)) throw AssertionError() // no local optimizations if (element10 in 3 until 1 != range1.contains(element10)) throw AssertionError() if (element10 !in 3 until 1 != !range1.contains(element10)) throw AssertionError() @@ -733,10 +541,10 @@ fun testR1xE10() { fun testR1xE11() { // with possible local optimizations - if (0.toDouble() in 3 until 1 != range1.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in 3 until 1 != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in 3 until 1) != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in 3 until 1) != range1.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in 3 until 1 != range1.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in 3 until 1 != !range1.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in 3 until 1) != !range1.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in 3 until 1) != range1.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in 3 until 1 != range1.contains(element11)) throw AssertionError() if (element11 !in 3 until 1 != !range1.contains(element11)) throw AssertionError() @@ -746,10 +554,10 @@ fun testR1xE11() { fun testR1xE12() { // with possible local optimizations - if (1.toByte() in 3 until 1 != range1.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in 3 until 1 != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in 3 until 1) != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in 3 until 1) != range1.contains(1.toByte())) throw AssertionError() + if (2.toByte() in 3 until 1 != range1.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in 3 until 1 != !range1.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in 3 until 1) != !range1.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in 3 until 1) != range1.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in 3 until 1 != range1.contains(element12)) throw AssertionError() if (element12 !in 3 until 1 != !range1.contains(element12)) throw AssertionError() @@ -759,10 +567,10 @@ fun testR1xE12() { fun testR1xE13() { // with possible local optimizations - if (1.toShort() in 3 until 1 != range1.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in 3 until 1 != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in 3 until 1) != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in 3 until 1) != range1.contains(1.toShort())) throw AssertionError() + if (2.toShort() in 3 until 1 != range1.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in 3 until 1 != !range1.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in 3 until 1) != !range1.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in 3 until 1) != range1.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in 3 until 1 != range1.contains(element13)) throw AssertionError() if (element13 !in 3 until 1 != !range1.contains(element13)) throw AssertionError() @@ -772,10 +580,10 @@ fun testR1xE13() { fun testR1xE14() { // with possible local optimizations - if (1 in 3 until 1 != range1.contains(1)) throw AssertionError() - if (1 !in 3 until 1 != !range1.contains(1)) throw AssertionError() - if (!(1 in 3 until 1) != !range1.contains(1)) throw AssertionError() - if (!(1 !in 3 until 1) != range1.contains(1)) throw AssertionError() + if (2 in 3 until 1 != range1.contains(2)) throw AssertionError() + if (2 !in 3 until 1 != !range1.contains(2)) throw AssertionError() + if (!(2 in 3 until 1) != !range1.contains(2)) throw AssertionError() + if (!(2 !in 3 until 1) != range1.contains(2)) throw AssertionError() // no local optimizations if (element14 in 3 until 1 != range1.contains(element14)) throw AssertionError() if (element14 !in 3 until 1 != !range1.contains(element14)) throw AssertionError() @@ -785,10 +593,10 @@ fun testR1xE14() { fun testR1xE15() { // with possible local optimizations - if (1.toLong() in 3 until 1 != range1.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in 3 until 1 != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in 3 until 1) != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in 3 until 1) != range1.contains(1.toLong())) throw AssertionError() + if (2.toLong() in 3 until 1 != range1.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in 3 until 1 != !range1.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in 3 until 1) != !range1.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in 3 until 1) != range1.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in 3 until 1 != range1.contains(element15)) throw AssertionError() if (element15 !in 3 until 1 != !range1.contains(element15)) throw AssertionError() @@ -798,10 +606,10 @@ fun testR1xE15() { fun testR1xE16() { // with possible local optimizations - if (1.toFloat() in 3 until 1 != range1.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in 3 until 1 != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in 3 until 1) != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in 3 until 1) != range1.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in 3 until 1 != range1.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in 3 until 1 != !range1.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in 3 until 1) != !range1.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in 3 until 1) != range1.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in 3 until 1 != range1.contains(element16)) throw AssertionError() if (element16 !in 3 until 1 != !range1.contains(element16)) throw AssertionError() @@ -811,10 +619,10 @@ fun testR1xE16() { fun testR1xE17() { // with possible local optimizations - if (1.toDouble() in 3 until 1 != range1.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in 3 until 1 != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in 3 until 1) != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in 3 until 1) != range1.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in 3 until 1 != range1.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in 3 until 1 != !range1.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in 3 until 1) != !range1.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in 3 until 1) != range1.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in 3 until 1 != range1.contains(element17)) throw AssertionError() if (element17 !in 3 until 1 != !range1.contains(element17)) throw AssertionError() @@ -824,10 +632,10 @@ fun testR1xE17() { fun testR1xE18() { // with possible local optimizations - if (2.toByte() in 3 until 1 != range1.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in 3 until 1 != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in 3 until 1) != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in 3 until 1) != range1.contains(2.toByte())) throw AssertionError() + if (3 in 3 until 1 != range1.contains(3)) throw AssertionError() + if (3 !in 3 until 1 != !range1.contains(3)) throw AssertionError() + if (!(3 in 3 until 1) != !range1.contains(3)) throw AssertionError() + if (!(3 !in 3 until 1) != range1.contains(3)) throw AssertionError() // no local optimizations if (element18 in 3 until 1 != range1.contains(element18)) throw AssertionError() if (element18 !in 3 until 1 != !range1.contains(element18)) throw AssertionError() @@ -837,10 +645,10 @@ fun testR1xE18() { fun testR1xE19() { // with possible local optimizations - if (2.toShort() in 3 until 1 != range1.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in 3 until 1 != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in 3 until 1) != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in 3 until 1) != range1.contains(2.toShort())) throw AssertionError() + if (3.toLong() in 3 until 1 != range1.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in 3 until 1 != !range1.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in 3 until 1) != !range1.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in 3 until 1) != range1.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in 3 until 1 != range1.contains(element19)) throw AssertionError() if (element19 !in 3 until 1 != !range1.contains(element19)) throw AssertionError() @@ -850,10 +658,10 @@ fun testR1xE19() { fun testR1xE20() { // with possible local optimizations - if (2 in 3 until 1 != range1.contains(2)) throw AssertionError() - if (2 !in 3 until 1 != !range1.contains(2)) throw AssertionError() - if (!(2 in 3 until 1) != !range1.contains(2)) throw AssertionError() - if (!(2 !in 3 until 1) != range1.contains(2)) throw AssertionError() + if (4.toByte() in 3 until 1 != range1.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in 3 until 1 != !range1.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in 3 until 1) != !range1.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in 3 until 1) != range1.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in 3 until 1 != range1.contains(element20)) throw AssertionError() if (element20 !in 3 until 1 != !range1.contains(element20)) throw AssertionError() @@ -863,10 +671,10 @@ fun testR1xE20() { fun testR1xE21() { // with possible local optimizations - if (2.toLong() in 3 until 1 != range1.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in 3 until 1 != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in 3 until 1) != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in 3 until 1) != range1.contains(2.toLong())) throw AssertionError() + if (4.toShort() in 3 until 1 != range1.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in 3 until 1 != !range1.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in 3 until 1) != !range1.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in 3 until 1) != range1.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in 3 until 1 != range1.contains(element21)) throw AssertionError() if (element21 !in 3 until 1 != !range1.contains(element21)) throw AssertionError() @@ -876,10 +684,10 @@ fun testR1xE21() { fun testR1xE22() { // with possible local optimizations - if (2.toFloat() in 3 until 1 != range1.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in 3 until 1 != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in 3 until 1) != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in 3 until 1) != range1.contains(2.toFloat())) throw AssertionError() + if (4 in 3 until 1 != range1.contains(4)) throw AssertionError() + if (4 !in 3 until 1 != !range1.contains(4)) throw AssertionError() + if (!(4 in 3 until 1) != !range1.contains(4)) throw AssertionError() + if (!(4 !in 3 until 1) != range1.contains(4)) throw AssertionError() // no local optimizations if (element22 in 3 until 1 != range1.contains(element22)) throw AssertionError() if (element22 !in 3 until 1 != !range1.contains(element22)) throw AssertionError() @@ -889,10 +697,10 @@ fun testR1xE22() { fun testR1xE23() { // with possible local optimizations - if (2.toDouble() in 3 until 1 != range1.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in 3 until 1 != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in 3 until 1) != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in 3 until 1) != range1.contains(2.toDouble())) throw AssertionError() + if (4.toLong() in 3 until 1 != range1.contains(4.toLong())) throw AssertionError() + if (4.toLong() !in 3 until 1 != !range1.contains(4.toLong())) throw AssertionError() + if (!(4.toLong() in 3 until 1) != !range1.contains(4.toLong())) throw AssertionError() + if (!(4.toLong() !in 3 until 1) != range1.contains(4.toLong())) throw AssertionError() // no local optimizations if (element23 in 3 until 1 != range1.contains(element23)) throw AssertionError() if (element23 !in 3 until 1 != !range1.contains(element23)) throw AssertionError() @@ -900,160 +708,4 @@ fun testR1xE23() { if (!(element23 !in 3 until 1) != range1.contains(element23)) throw AssertionError() } -fun testR1xE24() { - // with possible local optimizations - if (3.toByte() in 3 until 1 != range1.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in 3 until 1 != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in 3 until 1) != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in 3 until 1) != range1.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in 3 until 1 != range1.contains(element24)) throw AssertionError() - if (element24 !in 3 until 1 != !range1.contains(element24)) throw AssertionError() - if (!(element24 in 3 until 1) != !range1.contains(element24)) throw AssertionError() - if (!(element24 !in 3 until 1) != range1.contains(element24)) throw AssertionError() -} - -fun testR1xE25() { - // with possible local optimizations - if (3.toShort() in 3 until 1 != range1.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in 3 until 1 != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in 3 until 1) != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in 3 until 1) != range1.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in 3 until 1 != range1.contains(element25)) throw AssertionError() - if (element25 !in 3 until 1 != !range1.contains(element25)) throw AssertionError() - if (!(element25 in 3 until 1) != !range1.contains(element25)) throw AssertionError() - if (!(element25 !in 3 until 1) != range1.contains(element25)) throw AssertionError() -} - -fun testR1xE26() { - // with possible local optimizations - if (3 in 3 until 1 != range1.contains(3)) throw AssertionError() - if (3 !in 3 until 1 != !range1.contains(3)) throw AssertionError() - if (!(3 in 3 until 1) != !range1.contains(3)) throw AssertionError() - if (!(3 !in 3 until 1) != range1.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in 3 until 1 != range1.contains(element26)) throw AssertionError() - if (element26 !in 3 until 1 != !range1.contains(element26)) throw AssertionError() - if (!(element26 in 3 until 1) != !range1.contains(element26)) throw AssertionError() - if (!(element26 !in 3 until 1) != range1.contains(element26)) throw AssertionError() -} - -fun testR1xE27() { - // with possible local optimizations - if (3.toLong() in 3 until 1 != range1.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in 3 until 1 != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in 3 until 1) != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in 3 until 1) != range1.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in 3 until 1 != range1.contains(element27)) throw AssertionError() - if (element27 !in 3 until 1 != !range1.contains(element27)) throw AssertionError() - if (!(element27 in 3 until 1) != !range1.contains(element27)) throw AssertionError() - if (!(element27 !in 3 until 1) != range1.contains(element27)) throw AssertionError() -} - -fun testR1xE28() { - // with possible local optimizations - if (3.toFloat() in 3 until 1 != range1.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in 3 until 1 != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in 3 until 1) != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in 3 until 1) != range1.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in 3 until 1 != range1.contains(element28)) throw AssertionError() - if (element28 !in 3 until 1 != !range1.contains(element28)) throw AssertionError() - if (!(element28 in 3 until 1) != !range1.contains(element28)) throw AssertionError() - if (!(element28 !in 3 until 1) != range1.contains(element28)) throw AssertionError() -} - -fun testR1xE29() { - // with possible local optimizations - if (3.toDouble() in 3 until 1 != range1.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in 3 until 1 != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in 3 until 1) != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in 3 until 1) != range1.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in 3 until 1 != range1.contains(element29)) throw AssertionError() - if (element29 !in 3 until 1 != !range1.contains(element29)) throw AssertionError() - if (!(element29 in 3 until 1) != !range1.contains(element29)) throw AssertionError() - if (!(element29 !in 3 until 1) != range1.contains(element29)) throw AssertionError() -} - -fun testR1xE30() { - // with possible local optimizations - if (4.toByte() in 3 until 1 != range1.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in 3 until 1 != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in 3 until 1) != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in 3 until 1) != range1.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in 3 until 1 != range1.contains(element30)) throw AssertionError() - if (element30 !in 3 until 1 != !range1.contains(element30)) throw AssertionError() - if (!(element30 in 3 until 1) != !range1.contains(element30)) throw AssertionError() - if (!(element30 !in 3 until 1) != range1.contains(element30)) throw AssertionError() -} - -fun testR1xE31() { - // with possible local optimizations - if (4.toShort() in 3 until 1 != range1.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in 3 until 1 != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in 3 until 1) != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in 3 until 1) != range1.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in 3 until 1 != range1.contains(element31)) throw AssertionError() - if (element31 !in 3 until 1 != !range1.contains(element31)) throw AssertionError() - if (!(element31 in 3 until 1) != !range1.contains(element31)) throw AssertionError() - if (!(element31 !in 3 until 1) != range1.contains(element31)) throw AssertionError() -} - -fun testR1xE32() { - // with possible local optimizations - if (4 in 3 until 1 != range1.contains(4)) throw AssertionError() - if (4 !in 3 until 1 != !range1.contains(4)) throw AssertionError() - if (!(4 in 3 until 1) != !range1.contains(4)) throw AssertionError() - if (!(4 !in 3 until 1) != range1.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in 3 until 1 != range1.contains(element32)) throw AssertionError() - if (element32 !in 3 until 1 != !range1.contains(element32)) throw AssertionError() - if (!(element32 in 3 until 1) != !range1.contains(element32)) throw AssertionError() - if (!(element32 !in 3 until 1) != range1.contains(element32)) throw AssertionError() -} - -fun testR1xE33() { - // with possible local optimizations - if (4.toLong() in 3 until 1 != range1.contains(4.toLong())) throw AssertionError() - if (4.toLong() !in 3 until 1 != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() in 3 until 1) != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() !in 3 until 1) != range1.contains(4.toLong())) throw AssertionError() - // no local optimizations - if (element33 in 3 until 1 != range1.contains(element33)) throw AssertionError() - if (element33 !in 3 until 1 != !range1.contains(element33)) throw AssertionError() - if (!(element33 in 3 until 1) != !range1.contains(element33)) throw AssertionError() - if (!(element33 !in 3 until 1) != range1.contains(element33)) throw AssertionError() -} - -fun testR1xE34() { - // with possible local optimizations - if (4.toFloat() in 3 until 1 != range1.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in 3 until 1 != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in 3 until 1) != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in 3 until 1) != range1.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in 3 until 1 != range1.contains(element34)) throw AssertionError() - if (element34 !in 3 until 1 != !range1.contains(element34)) throw AssertionError() - if (!(element34 in 3 until 1) != !range1.contains(element34)) throw AssertionError() - if (!(element34 !in 3 until 1) != range1.contains(element34)) throw AssertionError() -} - -fun testR1xE35() { - // with possible local optimizations - if (4.toDouble() in 3 until 1 != range1.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in 3 until 1 != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in 3 until 1) != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in 3 until 1) != range1.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in 3 until 1 != range1.contains(element35)) throw AssertionError() - if (element35 !in 3 until 1 != !range1.contains(element35)) throw AssertionError() - if (!(element35 in 3 until 1) != !range1.contains(element35)) throw AssertionError() - if (!(element35 !in 3 until 1) != range1.contains(element35)) throw AssertionError() -} - diff --git a/compiler/testData/codegen/box/ranges/contains/generated/longRangeLiteral.kt b/compiler/testData/codegen/box/ranges/contains/generated/longRangeLiteral.kt index 56e3af6dba3..831cbad751b 100644 --- a/compiler/testData/codegen/box/ranges/contains/generated/longRangeLiteral.kt +++ b/compiler/testData/codegen/box/ranges/contains/generated/longRangeLiteral.kt @@ -11,38 +11,26 @@ val element0 = (-1).toByte() val element1 = (-1).toShort() val element2 = (-1) val element3 = (-1).toLong() -val element4 = (-1).toFloat() -val element5 = (-1).toDouble() -val element6 = 0.toByte() -val element7 = 0.toShort() -val element8 = 0 -val element9 = 0.toLong() -val element10 = 0.toFloat() -val element11 = 0.toDouble() -val element12 = 1.toByte() -val element13 = 1.toShort() -val element14 = 1 -val element15 = 1.toLong() -val element16 = 1.toFloat() -val element17 = 1.toDouble() -val element18 = 2.toByte() -val element19 = 2.toShort() -val element20 = 2 -val element21 = 2.toLong() -val element22 = 2.toFloat() -val element23 = 2.toDouble() -val element24 = 3.toByte() -val element25 = 3.toShort() -val element26 = 3 -val element27 = 3.toLong() -val element28 = 3.toFloat() -val element29 = 3.toDouble() -val element30 = 4.toByte() -val element31 = 4.toShort() -val element32 = 4 -val element33 = 4.toLong() -val element34 = 4.toFloat() -val element35 = 4.toDouble() +val element4 = 0.toByte() +val element5 = 0.toShort() +val element6 = 0 +val element7 = 0.toLong() +val element8 = 1.toByte() +val element9 = 1.toShort() +val element10 = 1 +val element11 = 1.toLong() +val element12 = 2.toByte() +val element13 = 2.toShort() +val element14 = 2 +val element15 = 2.toLong() +val element16 = 3.toByte() +val element17 = 3.toShort() +val element18 = 3 +val element19 = 3.toLong() +val element20 = 4.toByte() +val element21 = 4.toShort() +val element22 = 4 +val element23 = 4.toLong() fun box(): String { testR0xE0() @@ -69,18 +57,6 @@ fun box(): String { testR0xE21() testR0xE22() testR0xE23() - testR0xE24() - testR0xE25() - testR0xE26() - testR0xE27() - testR0xE28() - testR0xE29() - testR0xE30() - testR0xE31() - testR0xE32() - testR0xE33() - testR0xE34() - testR0xE35() testR1xE0() testR1xE1() testR1xE2() @@ -105,18 +81,6 @@ fun box(): String { testR1xE21() testR1xE22() testR1xE23() - testR1xE24() - testR1xE25() - testR1xE26() - testR1xE27() - testR1xE28() - testR1xE29() - testR1xE30() - testR1xE31() - testR1xE32() - testR1xE33() - testR1xE34() - testR1xE35() return "OK" } @@ -174,10 +138,10 @@ fun testR0xE3() { fun testR0xE4() { // with possible local optimizations - if ((-1).toFloat() in 1L .. 3L != range0.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in 1L .. 3L != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in 1L .. 3L) != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in 1L .. 3L) != range0.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in 1L .. 3L != range0.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in 1L .. 3L != !range0.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in 1L .. 3L) != !range0.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in 1L .. 3L) != range0.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in 1L .. 3L != range0.contains(element4)) throw AssertionError() if (element4 !in 1L .. 3L != !range0.contains(element4)) throw AssertionError() @@ -187,10 +151,10 @@ fun testR0xE4() { fun testR0xE5() { // with possible local optimizations - if ((-1).toDouble() in 1L .. 3L != range0.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in 1L .. 3L != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in 1L .. 3L) != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in 1L .. 3L) != range0.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in 1L .. 3L != range0.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in 1L .. 3L != !range0.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in 1L .. 3L) != !range0.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in 1L .. 3L) != range0.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in 1L .. 3L != range0.contains(element5)) throw AssertionError() if (element5 !in 1L .. 3L != !range0.contains(element5)) throw AssertionError() @@ -200,10 +164,10 @@ fun testR0xE5() { fun testR0xE6() { // with possible local optimizations - if (0.toByte() in 1L .. 3L != range0.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in 1L .. 3L != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in 1L .. 3L) != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in 1L .. 3L) != range0.contains(0.toByte())) throw AssertionError() + if (0 in 1L .. 3L != range0.contains(0)) throw AssertionError() + if (0 !in 1L .. 3L != !range0.contains(0)) throw AssertionError() + if (!(0 in 1L .. 3L) != !range0.contains(0)) throw AssertionError() + if (!(0 !in 1L .. 3L) != range0.contains(0)) throw AssertionError() // no local optimizations if (element6 in 1L .. 3L != range0.contains(element6)) throw AssertionError() if (element6 !in 1L .. 3L != !range0.contains(element6)) throw AssertionError() @@ -213,10 +177,10 @@ fun testR0xE6() { fun testR0xE7() { // with possible local optimizations - if (0.toShort() in 1L .. 3L != range0.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in 1L .. 3L != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in 1L .. 3L) != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in 1L .. 3L) != range0.contains(0.toShort())) throw AssertionError() + if (0.toLong() in 1L .. 3L != range0.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in 1L .. 3L != !range0.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in 1L .. 3L) != !range0.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in 1L .. 3L) != range0.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in 1L .. 3L != range0.contains(element7)) throw AssertionError() if (element7 !in 1L .. 3L != !range0.contains(element7)) throw AssertionError() @@ -226,10 +190,10 @@ fun testR0xE7() { fun testR0xE8() { // with possible local optimizations - if (0 in 1L .. 3L != range0.contains(0)) throw AssertionError() - if (0 !in 1L .. 3L != !range0.contains(0)) throw AssertionError() - if (!(0 in 1L .. 3L) != !range0.contains(0)) throw AssertionError() - if (!(0 !in 1L .. 3L) != range0.contains(0)) throw AssertionError() + if (1.toByte() in 1L .. 3L != range0.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in 1L .. 3L != !range0.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in 1L .. 3L) != !range0.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in 1L .. 3L) != range0.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in 1L .. 3L != range0.contains(element8)) throw AssertionError() if (element8 !in 1L .. 3L != !range0.contains(element8)) throw AssertionError() @@ -239,10 +203,10 @@ fun testR0xE8() { fun testR0xE9() { // with possible local optimizations - if (0.toLong() in 1L .. 3L != range0.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in 1L .. 3L != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in 1L .. 3L) != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in 1L .. 3L) != range0.contains(0.toLong())) throw AssertionError() + if (1.toShort() in 1L .. 3L != range0.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in 1L .. 3L != !range0.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in 1L .. 3L) != !range0.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in 1L .. 3L) != range0.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in 1L .. 3L != range0.contains(element9)) throw AssertionError() if (element9 !in 1L .. 3L != !range0.contains(element9)) throw AssertionError() @@ -252,10 +216,10 @@ fun testR0xE9() { fun testR0xE10() { // with possible local optimizations - if (0.toFloat() in 1L .. 3L != range0.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in 1L .. 3L != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in 1L .. 3L) != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in 1L .. 3L) != range0.contains(0.toFloat())) throw AssertionError() + if (1 in 1L .. 3L != range0.contains(1)) throw AssertionError() + if (1 !in 1L .. 3L != !range0.contains(1)) throw AssertionError() + if (!(1 in 1L .. 3L) != !range0.contains(1)) throw AssertionError() + if (!(1 !in 1L .. 3L) != range0.contains(1)) throw AssertionError() // no local optimizations if (element10 in 1L .. 3L != range0.contains(element10)) throw AssertionError() if (element10 !in 1L .. 3L != !range0.contains(element10)) throw AssertionError() @@ -265,10 +229,10 @@ fun testR0xE10() { fun testR0xE11() { // with possible local optimizations - if (0.toDouble() in 1L .. 3L != range0.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in 1L .. 3L != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in 1L .. 3L) != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in 1L .. 3L) != range0.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in 1L .. 3L != range0.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in 1L .. 3L != !range0.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in 1L .. 3L) != !range0.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in 1L .. 3L) != range0.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in 1L .. 3L != range0.contains(element11)) throw AssertionError() if (element11 !in 1L .. 3L != !range0.contains(element11)) throw AssertionError() @@ -278,10 +242,10 @@ fun testR0xE11() { fun testR0xE12() { // with possible local optimizations - if (1.toByte() in 1L .. 3L != range0.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in 1L .. 3L != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in 1L .. 3L) != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in 1L .. 3L) != range0.contains(1.toByte())) throw AssertionError() + if (2.toByte() in 1L .. 3L != range0.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in 1L .. 3L != !range0.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in 1L .. 3L) != !range0.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in 1L .. 3L) != range0.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in 1L .. 3L != range0.contains(element12)) throw AssertionError() if (element12 !in 1L .. 3L != !range0.contains(element12)) throw AssertionError() @@ -291,10 +255,10 @@ fun testR0xE12() { fun testR0xE13() { // with possible local optimizations - if (1.toShort() in 1L .. 3L != range0.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in 1L .. 3L != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in 1L .. 3L) != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in 1L .. 3L) != range0.contains(1.toShort())) throw AssertionError() + if (2.toShort() in 1L .. 3L != range0.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in 1L .. 3L != !range0.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in 1L .. 3L) != !range0.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in 1L .. 3L) != range0.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in 1L .. 3L != range0.contains(element13)) throw AssertionError() if (element13 !in 1L .. 3L != !range0.contains(element13)) throw AssertionError() @@ -304,10 +268,10 @@ fun testR0xE13() { fun testR0xE14() { // with possible local optimizations - if (1 in 1L .. 3L != range0.contains(1)) throw AssertionError() - if (1 !in 1L .. 3L != !range0.contains(1)) throw AssertionError() - if (!(1 in 1L .. 3L) != !range0.contains(1)) throw AssertionError() - if (!(1 !in 1L .. 3L) != range0.contains(1)) throw AssertionError() + if (2 in 1L .. 3L != range0.contains(2)) throw AssertionError() + if (2 !in 1L .. 3L != !range0.contains(2)) throw AssertionError() + if (!(2 in 1L .. 3L) != !range0.contains(2)) throw AssertionError() + if (!(2 !in 1L .. 3L) != range0.contains(2)) throw AssertionError() // no local optimizations if (element14 in 1L .. 3L != range0.contains(element14)) throw AssertionError() if (element14 !in 1L .. 3L != !range0.contains(element14)) throw AssertionError() @@ -317,10 +281,10 @@ fun testR0xE14() { fun testR0xE15() { // with possible local optimizations - if (1.toLong() in 1L .. 3L != range0.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in 1L .. 3L != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in 1L .. 3L) != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in 1L .. 3L) != range0.contains(1.toLong())) throw AssertionError() + if (2.toLong() in 1L .. 3L != range0.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in 1L .. 3L != !range0.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in 1L .. 3L) != !range0.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in 1L .. 3L) != range0.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in 1L .. 3L != range0.contains(element15)) throw AssertionError() if (element15 !in 1L .. 3L != !range0.contains(element15)) throw AssertionError() @@ -330,10 +294,10 @@ fun testR0xE15() { fun testR0xE16() { // with possible local optimizations - if (1.toFloat() in 1L .. 3L != range0.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in 1L .. 3L != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in 1L .. 3L) != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in 1L .. 3L) != range0.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in 1L .. 3L != range0.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in 1L .. 3L != !range0.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in 1L .. 3L) != !range0.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in 1L .. 3L) != range0.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in 1L .. 3L != range0.contains(element16)) throw AssertionError() if (element16 !in 1L .. 3L != !range0.contains(element16)) throw AssertionError() @@ -343,10 +307,10 @@ fun testR0xE16() { fun testR0xE17() { // with possible local optimizations - if (1.toDouble() in 1L .. 3L != range0.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in 1L .. 3L != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in 1L .. 3L) != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in 1L .. 3L) != range0.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in 1L .. 3L != range0.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in 1L .. 3L != !range0.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in 1L .. 3L) != !range0.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in 1L .. 3L) != range0.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in 1L .. 3L != range0.contains(element17)) throw AssertionError() if (element17 !in 1L .. 3L != !range0.contains(element17)) throw AssertionError() @@ -356,10 +320,10 @@ fun testR0xE17() { fun testR0xE18() { // with possible local optimizations - if (2.toByte() in 1L .. 3L != range0.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in 1L .. 3L != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in 1L .. 3L) != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in 1L .. 3L) != range0.contains(2.toByte())) throw AssertionError() + if (3 in 1L .. 3L != range0.contains(3)) throw AssertionError() + if (3 !in 1L .. 3L != !range0.contains(3)) throw AssertionError() + if (!(3 in 1L .. 3L) != !range0.contains(3)) throw AssertionError() + if (!(3 !in 1L .. 3L) != range0.contains(3)) throw AssertionError() // no local optimizations if (element18 in 1L .. 3L != range0.contains(element18)) throw AssertionError() if (element18 !in 1L .. 3L != !range0.contains(element18)) throw AssertionError() @@ -369,10 +333,10 @@ fun testR0xE18() { fun testR0xE19() { // with possible local optimizations - if (2.toShort() in 1L .. 3L != range0.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in 1L .. 3L != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in 1L .. 3L) != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in 1L .. 3L) != range0.contains(2.toShort())) throw AssertionError() + if (3.toLong() in 1L .. 3L != range0.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in 1L .. 3L != !range0.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in 1L .. 3L) != !range0.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in 1L .. 3L) != range0.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in 1L .. 3L != range0.contains(element19)) throw AssertionError() if (element19 !in 1L .. 3L != !range0.contains(element19)) throw AssertionError() @@ -382,10 +346,10 @@ fun testR0xE19() { fun testR0xE20() { // with possible local optimizations - if (2 in 1L .. 3L != range0.contains(2)) throw AssertionError() - if (2 !in 1L .. 3L != !range0.contains(2)) throw AssertionError() - if (!(2 in 1L .. 3L) != !range0.contains(2)) throw AssertionError() - if (!(2 !in 1L .. 3L) != range0.contains(2)) throw AssertionError() + if (4.toByte() in 1L .. 3L != range0.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in 1L .. 3L != !range0.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in 1L .. 3L) != !range0.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in 1L .. 3L) != range0.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in 1L .. 3L != range0.contains(element20)) throw AssertionError() if (element20 !in 1L .. 3L != !range0.contains(element20)) throw AssertionError() @@ -395,10 +359,10 @@ fun testR0xE20() { fun testR0xE21() { // with possible local optimizations - if (2.toLong() in 1L .. 3L != range0.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in 1L .. 3L != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in 1L .. 3L) != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in 1L .. 3L) != range0.contains(2.toLong())) throw AssertionError() + if (4.toShort() in 1L .. 3L != range0.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in 1L .. 3L != !range0.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in 1L .. 3L) != !range0.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in 1L .. 3L) != range0.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in 1L .. 3L != range0.contains(element21)) throw AssertionError() if (element21 !in 1L .. 3L != !range0.contains(element21)) throw AssertionError() @@ -408,10 +372,10 @@ fun testR0xE21() { fun testR0xE22() { // with possible local optimizations - if (2.toFloat() in 1L .. 3L != range0.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in 1L .. 3L != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in 1L .. 3L) != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in 1L .. 3L) != range0.contains(2.toFloat())) throw AssertionError() + if (4 in 1L .. 3L != range0.contains(4)) throw AssertionError() + if (4 !in 1L .. 3L != !range0.contains(4)) throw AssertionError() + if (!(4 in 1L .. 3L) != !range0.contains(4)) throw AssertionError() + if (!(4 !in 1L .. 3L) != range0.contains(4)) throw AssertionError() // no local optimizations if (element22 in 1L .. 3L != range0.contains(element22)) throw AssertionError() if (element22 !in 1L .. 3L != !range0.contains(element22)) throw AssertionError() @@ -420,172 +384,16 @@ fun testR0xE22() { } fun testR0xE23() { - // with possible local optimizations - if (2.toDouble() in 1L .. 3L != range0.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in 1L .. 3L != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in 1L .. 3L) != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in 1L .. 3L) != range0.contains(2.toDouble())) throw AssertionError() - // no local optimizations - if (element23 in 1L .. 3L != range0.contains(element23)) throw AssertionError() - if (element23 !in 1L .. 3L != !range0.contains(element23)) throw AssertionError() - if (!(element23 in 1L .. 3L) != !range0.contains(element23)) throw AssertionError() - if (!(element23 !in 1L .. 3L) != range0.contains(element23)) throw AssertionError() -} - -fun testR0xE24() { - // with possible local optimizations - if (3.toByte() in 1L .. 3L != range0.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in 1L .. 3L != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in 1L .. 3L) != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in 1L .. 3L) != range0.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in 1L .. 3L != range0.contains(element24)) throw AssertionError() - if (element24 !in 1L .. 3L != !range0.contains(element24)) throw AssertionError() - if (!(element24 in 1L .. 3L) != !range0.contains(element24)) throw AssertionError() - if (!(element24 !in 1L .. 3L) != range0.contains(element24)) throw AssertionError() -} - -fun testR0xE25() { - // with possible local optimizations - if (3.toShort() in 1L .. 3L != range0.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in 1L .. 3L != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in 1L .. 3L) != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in 1L .. 3L) != range0.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in 1L .. 3L != range0.contains(element25)) throw AssertionError() - if (element25 !in 1L .. 3L != !range0.contains(element25)) throw AssertionError() - if (!(element25 in 1L .. 3L) != !range0.contains(element25)) throw AssertionError() - if (!(element25 !in 1L .. 3L) != range0.contains(element25)) throw AssertionError() -} - -fun testR0xE26() { - // with possible local optimizations - if (3 in 1L .. 3L != range0.contains(3)) throw AssertionError() - if (3 !in 1L .. 3L != !range0.contains(3)) throw AssertionError() - if (!(3 in 1L .. 3L) != !range0.contains(3)) throw AssertionError() - if (!(3 !in 1L .. 3L) != range0.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in 1L .. 3L != range0.contains(element26)) throw AssertionError() - if (element26 !in 1L .. 3L != !range0.contains(element26)) throw AssertionError() - if (!(element26 in 1L .. 3L) != !range0.contains(element26)) throw AssertionError() - if (!(element26 !in 1L .. 3L) != range0.contains(element26)) throw AssertionError() -} - -fun testR0xE27() { - // with possible local optimizations - if (3.toLong() in 1L .. 3L != range0.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in 1L .. 3L != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in 1L .. 3L) != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in 1L .. 3L) != range0.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in 1L .. 3L != range0.contains(element27)) throw AssertionError() - if (element27 !in 1L .. 3L != !range0.contains(element27)) throw AssertionError() - if (!(element27 in 1L .. 3L) != !range0.contains(element27)) throw AssertionError() - if (!(element27 !in 1L .. 3L) != range0.contains(element27)) throw AssertionError() -} - -fun testR0xE28() { - // with possible local optimizations - if (3.toFloat() in 1L .. 3L != range0.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in 1L .. 3L != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in 1L .. 3L) != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in 1L .. 3L) != range0.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in 1L .. 3L != range0.contains(element28)) throw AssertionError() - if (element28 !in 1L .. 3L != !range0.contains(element28)) throw AssertionError() - if (!(element28 in 1L .. 3L) != !range0.contains(element28)) throw AssertionError() - if (!(element28 !in 1L .. 3L) != range0.contains(element28)) throw AssertionError() -} - -fun testR0xE29() { - // with possible local optimizations - if (3.toDouble() in 1L .. 3L != range0.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in 1L .. 3L != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in 1L .. 3L) != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in 1L .. 3L) != range0.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in 1L .. 3L != range0.contains(element29)) throw AssertionError() - if (element29 !in 1L .. 3L != !range0.contains(element29)) throw AssertionError() - if (!(element29 in 1L .. 3L) != !range0.contains(element29)) throw AssertionError() - if (!(element29 !in 1L .. 3L) != range0.contains(element29)) throw AssertionError() -} - -fun testR0xE30() { - // with possible local optimizations - if (4.toByte() in 1L .. 3L != range0.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in 1L .. 3L != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in 1L .. 3L) != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in 1L .. 3L) != range0.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in 1L .. 3L != range0.contains(element30)) throw AssertionError() - if (element30 !in 1L .. 3L != !range0.contains(element30)) throw AssertionError() - if (!(element30 in 1L .. 3L) != !range0.contains(element30)) throw AssertionError() - if (!(element30 !in 1L .. 3L) != range0.contains(element30)) throw AssertionError() -} - -fun testR0xE31() { - // with possible local optimizations - if (4.toShort() in 1L .. 3L != range0.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in 1L .. 3L != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in 1L .. 3L) != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in 1L .. 3L) != range0.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in 1L .. 3L != range0.contains(element31)) throw AssertionError() - if (element31 !in 1L .. 3L != !range0.contains(element31)) throw AssertionError() - if (!(element31 in 1L .. 3L) != !range0.contains(element31)) throw AssertionError() - if (!(element31 !in 1L .. 3L) != range0.contains(element31)) throw AssertionError() -} - -fun testR0xE32() { - // with possible local optimizations - if (4 in 1L .. 3L != range0.contains(4)) throw AssertionError() - if (4 !in 1L .. 3L != !range0.contains(4)) throw AssertionError() - if (!(4 in 1L .. 3L) != !range0.contains(4)) throw AssertionError() - if (!(4 !in 1L .. 3L) != range0.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in 1L .. 3L != range0.contains(element32)) throw AssertionError() - if (element32 !in 1L .. 3L != !range0.contains(element32)) throw AssertionError() - if (!(element32 in 1L .. 3L) != !range0.contains(element32)) throw AssertionError() - if (!(element32 !in 1L .. 3L) != range0.contains(element32)) throw AssertionError() -} - -fun testR0xE33() { // with possible local optimizations if (4.toLong() in 1L .. 3L != range0.contains(4.toLong())) throw AssertionError() if (4.toLong() !in 1L .. 3L != !range0.contains(4.toLong())) throw AssertionError() if (!(4.toLong() in 1L .. 3L) != !range0.contains(4.toLong())) throw AssertionError() if (!(4.toLong() !in 1L .. 3L) != range0.contains(4.toLong())) throw AssertionError() // no local optimizations - if (element33 in 1L .. 3L != range0.contains(element33)) throw AssertionError() - if (element33 !in 1L .. 3L != !range0.contains(element33)) throw AssertionError() - if (!(element33 in 1L .. 3L) != !range0.contains(element33)) throw AssertionError() - if (!(element33 !in 1L .. 3L) != range0.contains(element33)) throw AssertionError() -} - -fun testR0xE34() { - // with possible local optimizations - if (4.toFloat() in 1L .. 3L != range0.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in 1L .. 3L != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in 1L .. 3L) != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in 1L .. 3L) != range0.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in 1L .. 3L != range0.contains(element34)) throw AssertionError() - if (element34 !in 1L .. 3L != !range0.contains(element34)) throw AssertionError() - if (!(element34 in 1L .. 3L) != !range0.contains(element34)) throw AssertionError() - if (!(element34 !in 1L .. 3L) != range0.contains(element34)) throw AssertionError() -} - -fun testR0xE35() { - // with possible local optimizations - if (4.toDouble() in 1L .. 3L != range0.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in 1L .. 3L != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in 1L .. 3L) != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in 1L .. 3L) != range0.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in 1L .. 3L != range0.contains(element35)) throw AssertionError() - if (element35 !in 1L .. 3L != !range0.contains(element35)) throw AssertionError() - if (!(element35 in 1L .. 3L) != !range0.contains(element35)) throw AssertionError() - if (!(element35 !in 1L .. 3L) != range0.contains(element35)) throw AssertionError() + if (element23 in 1L .. 3L != range0.contains(element23)) throw AssertionError() + if (element23 !in 1L .. 3L != !range0.contains(element23)) throw AssertionError() + if (!(element23 in 1L .. 3L) != !range0.contains(element23)) throw AssertionError() + if (!(element23 !in 1L .. 3L) != range0.contains(element23)) throw AssertionError() } fun testR1xE0() { @@ -642,10 +450,10 @@ fun testR1xE3() { fun testR1xE4() { // with possible local optimizations - if ((-1).toFloat() in 3L .. 1L != range1.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in 3L .. 1L != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in 3L .. 1L) != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in 3L .. 1L) != range1.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in 3L .. 1L != range1.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in 3L .. 1L != !range1.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in 3L .. 1L) != !range1.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in 3L .. 1L) != range1.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in 3L .. 1L != range1.contains(element4)) throw AssertionError() if (element4 !in 3L .. 1L != !range1.contains(element4)) throw AssertionError() @@ -655,10 +463,10 @@ fun testR1xE4() { fun testR1xE5() { // with possible local optimizations - if ((-1).toDouble() in 3L .. 1L != range1.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in 3L .. 1L != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in 3L .. 1L) != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in 3L .. 1L) != range1.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in 3L .. 1L != range1.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in 3L .. 1L != !range1.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in 3L .. 1L) != !range1.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in 3L .. 1L) != range1.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in 3L .. 1L != range1.contains(element5)) throw AssertionError() if (element5 !in 3L .. 1L != !range1.contains(element5)) throw AssertionError() @@ -668,10 +476,10 @@ fun testR1xE5() { fun testR1xE6() { // with possible local optimizations - if (0.toByte() in 3L .. 1L != range1.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in 3L .. 1L != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in 3L .. 1L) != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in 3L .. 1L) != range1.contains(0.toByte())) throw AssertionError() + if (0 in 3L .. 1L != range1.contains(0)) throw AssertionError() + if (0 !in 3L .. 1L != !range1.contains(0)) throw AssertionError() + if (!(0 in 3L .. 1L) != !range1.contains(0)) throw AssertionError() + if (!(0 !in 3L .. 1L) != range1.contains(0)) throw AssertionError() // no local optimizations if (element6 in 3L .. 1L != range1.contains(element6)) throw AssertionError() if (element6 !in 3L .. 1L != !range1.contains(element6)) throw AssertionError() @@ -681,10 +489,10 @@ fun testR1xE6() { fun testR1xE7() { // with possible local optimizations - if (0.toShort() in 3L .. 1L != range1.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in 3L .. 1L != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in 3L .. 1L) != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in 3L .. 1L) != range1.contains(0.toShort())) throw AssertionError() + if (0.toLong() in 3L .. 1L != range1.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in 3L .. 1L != !range1.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in 3L .. 1L) != !range1.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in 3L .. 1L) != range1.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in 3L .. 1L != range1.contains(element7)) throw AssertionError() if (element7 !in 3L .. 1L != !range1.contains(element7)) throw AssertionError() @@ -694,10 +502,10 @@ fun testR1xE7() { fun testR1xE8() { // with possible local optimizations - if (0 in 3L .. 1L != range1.contains(0)) throw AssertionError() - if (0 !in 3L .. 1L != !range1.contains(0)) throw AssertionError() - if (!(0 in 3L .. 1L) != !range1.contains(0)) throw AssertionError() - if (!(0 !in 3L .. 1L) != range1.contains(0)) throw AssertionError() + if (1.toByte() in 3L .. 1L != range1.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in 3L .. 1L != !range1.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in 3L .. 1L) != !range1.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in 3L .. 1L) != range1.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in 3L .. 1L != range1.contains(element8)) throw AssertionError() if (element8 !in 3L .. 1L != !range1.contains(element8)) throw AssertionError() @@ -707,10 +515,10 @@ fun testR1xE8() { fun testR1xE9() { // with possible local optimizations - if (0.toLong() in 3L .. 1L != range1.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in 3L .. 1L != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in 3L .. 1L) != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in 3L .. 1L) != range1.contains(0.toLong())) throw AssertionError() + if (1.toShort() in 3L .. 1L != range1.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in 3L .. 1L != !range1.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in 3L .. 1L) != !range1.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in 3L .. 1L) != range1.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in 3L .. 1L != range1.contains(element9)) throw AssertionError() if (element9 !in 3L .. 1L != !range1.contains(element9)) throw AssertionError() @@ -720,10 +528,10 @@ fun testR1xE9() { fun testR1xE10() { // with possible local optimizations - if (0.toFloat() in 3L .. 1L != range1.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in 3L .. 1L != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in 3L .. 1L) != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in 3L .. 1L) != range1.contains(0.toFloat())) throw AssertionError() + if (1 in 3L .. 1L != range1.contains(1)) throw AssertionError() + if (1 !in 3L .. 1L != !range1.contains(1)) throw AssertionError() + if (!(1 in 3L .. 1L) != !range1.contains(1)) throw AssertionError() + if (!(1 !in 3L .. 1L) != range1.contains(1)) throw AssertionError() // no local optimizations if (element10 in 3L .. 1L != range1.contains(element10)) throw AssertionError() if (element10 !in 3L .. 1L != !range1.contains(element10)) throw AssertionError() @@ -733,10 +541,10 @@ fun testR1xE10() { fun testR1xE11() { // with possible local optimizations - if (0.toDouble() in 3L .. 1L != range1.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in 3L .. 1L != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in 3L .. 1L) != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in 3L .. 1L) != range1.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in 3L .. 1L != range1.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in 3L .. 1L != !range1.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in 3L .. 1L) != !range1.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in 3L .. 1L) != range1.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in 3L .. 1L != range1.contains(element11)) throw AssertionError() if (element11 !in 3L .. 1L != !range1.contains(element11)) throw AssertionError() @@ -746,10 +554,10 @@ fun testR1xE11() { fun testR1xE12() { // with possible local optimizations - if (1.toByte() in 3L .. 1L != range1.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in 3L .. 1L != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in 3L .. 1L) != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in 3L .. 1L) != range1.contains(1.toByte())) throw AssertionError() + if (2.toByte() in 3L .. 1L != range1.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in 3L .. 1L != !range1.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in 3L .. 1L) != !range1.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in 3L .. 1L) != range1.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in 3L .. 1L != range1.contains(element12)) throw AssertionError() if (element12 !in 3L .. 1L != !range1.contains(element12)) throw AssertionError() @@ -759,10 +567,10 @@ fun testR1xE12() { fun testR1xE13() { // with possible local optimizations - if (1.toShort() in 3L .. 1L != range1.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in 3L .. 1L != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in 3L .. 1L) != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in 3L .. 1L) != range1.contains(1.toShort())) throw AssertionError() + if (2.toShort() in 3L .. 1L != range1.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in 3L .. 1L != !range1.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in 3L .. 1L) != !range1.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in 3L .. 1L) != range1.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in 3L .. 1L != range1.contains(element13)) throw AssertionError() if (element13 !in 3L .. 1L != !range1.contains(element13)) throw AssertionError() @@ -772,10 +580,10 @@ fun testR1xE13() { fun testR1xE14() { // with possible local optimizations - if (1 in 3L .. 1L != range1.contains(1)) throw AssertionError() - if (1 !in 3L .. 1L != !range1.contains(1)) throw AssertionError() - if (!(1 in 3L .. 1L) != !range1.contains(1)) throw AssertionError() - if (!(1 !in 3L .. 1L) != range1.contains(1)) throw AssertionError() + if (2 in 3L .. 1L != range1.contains(2)) throw AssertionError() + if (2 !in 3L .. 1L != !range1.contains(2)) throw AssertionError() + if (!(2 in 3L .. 1L) != !range1.contains(2)) throw AssertionError() + if (!(2 !in 3L .. 1L) != range1.contains(2)) throw AssertionError() // no local optimizations if (element14 in 3L .. 1L != range1.contains(element14)) throw AssertionError() if (element14 !in 3L .. 1L != !range1.contains(element14)) throw AssertionError() @@ -785,10 +593,10 @@ fun testR1xE14() { fun testR1xE15() { // with possible local optimizations - if (1.toLong() in 3L .. 1L != range1.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in 3L .. 1L != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in 3L .. 1L) != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in 3L .. 1L) != range1.contains(1.toLong())) throw AssertionError() + if (2.toLong() in 3L .. 1L != range1.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in 3L .. 1L != !range1.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in 3L .. 1L) != !range1.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in 3L .. 1L) != range1.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in 3L .. 1L != range1.contains(element15)) throw AssertionError() if (element15 !in 3L .. 1L != !range1.contains(element15)) throw AssertionError() @@ -798,10 +606,10 @@ fun testR1xE15() { fun testR1xE16() { // with possible local optimizations - if (1.toFloat() in 3L .. 1L != range1.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in 3L .. 1L != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in 3L .. 1L) != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in 3L .. 1L) != range1.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in 3L .. 1L != range1.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in 3L .. 1L != !range1.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in 3L .. 1L) != !range1.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in 3L .. 1L) != range1.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in 3L .. 1L != range1.contains(element16)) throw AssertionError() if (element16 !in 3L .. 1L != !range1.contains(element16)) throw AssertionError() @@ -811,10 +619,10 @@ fun testR1xE16() { fun testR1xE17() { // with possible local optimizations - if (1.toDouble() in 3L .. 1L != range1.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in 3L .. 1L != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in 3L .. 1L) != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in 3L .. 1L) != range1.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in 3L .. 1L != range1.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in 3L .. 1L != !range1.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in 3L .. 1L) != !range1.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in 3L .. 1L) != range1.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in 3L .. 1L != range1.contains(element17)) throw AssertionError() if (element17 !in 3L .. 1L != !range1.contains(element17)) throw AssertionError() @@ -824,10 +632,10 @@ fun testR1xE17() { fun testR1xE18() { // with possible local optimizations - if (2.toByte() in 3L .. 1L != range1.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in 3L .. 1L != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in 3L .. 1L) != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in 3L .. 1L) != range1.contains(2.toByte())) throw AssertionError() + if (3 in 3L .. 1L != range1.contains(3)) throw AssertionError() + if (3 !in 3L .. 1L != !range1.contains(3)) throw AssertionError() + if (!(3 in 3L .. 1L) != !range1.contains(3)) throw AssertionError() + if (!(3 !in 3L .. 1L) != range1.contains(3)) throw AssertionError() // no local optimizations if (element18 in 3L .. 1L != range1.contains(element18)) throw AssertionError() if (element18 !in 3L .. 1L != !range1.contains(element18)) throw AssertionError() @@ -837,10 +645,10 @@ fun testR1xE18() { fun testR1xE19() { // with possible local optimizations - if (2.toShort() in 3L .. 1L != range1.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in 3L .. 1L != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in 3L .. 1L) != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in 3L .. 1L) != range1.contains(2.toShort())) throw AssertionError() + if (3.toLong() in 3L .. 1L != range1.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in 3L .. 1L != !range1.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in 3L .. 1L) != !range1.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in 3L .. 1L) != range1.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in 3L .. 1L != range1.contains(element19)) throw AssertionError() if (element19 !in 3L .. 1L != !range1.contains(element19)) throw AssertionError() @@ -850,10 +658,10 @@ fun testR1xE19() { fun testR1xE20() { // with possible local optimizations - if (2 in 3L .. 1L != range1.contains(2)) throw AssertionError() - if (2 !in 3L .. 1L != !range1.contains(2)) throw AssertionError() - if (!(2 in 3L .. 1L) != !range1.contains(2)) throw AssertionError() - if (!(2 !in 3L .. 1L) != range1.contains(2)) throw AssertionError() + if (4.toByte() in 3L .. 1L != range1.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in 3L .. 1L != !range1.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in 3L .. 1L) != !range1.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in 3L .. 1L) != range1.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in 3L .. 1L != range1.contains(element20)) throw AssertionError() if (element20 !in 3L .. 1L != !range1.contains(element20)) throw AssertionError() @@ -863,10 +671,10 @@ fun testR1xE20() { fun testR1xE21() { // with possible local optimizations - if (2.toLong() in 3L .. 1L != range1.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in 3L .. 1L != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in 3L .. 1L) != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in 3L .. 1L) != range1.contains(2.toLong())) throw AssertionError() + if (4.toShort() in 3L .. 1L != range1.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in 3L .. 1L != !range1.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in 3L .. 1L) != !range1.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in 3L .. 1L) != range1.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in 3L .. 1L != range1.contains(element21)) throw AssertionError() if (element21 !in 3L .. 1L != !range1.contains(element21)) throw AssertionError() @@ -876,10 +684,10 @@ fun testR1xE21() { fun testR1xE22() { // with possible local optimizations - if (2.toFloat() in 3L .. 1L != range1.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in 3L .. 1L != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in 3L .. 1L) != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in 3L .. 1L) != range1.contains(2.toFloat())) throw AssertionError() + if (4 in 3L .. 1L != range1.contains(4)) throw AssertionError() + if (4 !in 3L .. 1L != !range1.contains(4)) throw AssertionError() + if (!(4 in 3L .. 1L) != !range1.contains(4)) throw AssertionError() + if (!(4 !in 3L .. 1L) != range1.contains(4)) throw AssertionError() // no local optimizations if (element22 in 3L .. 1L != range1.contains(element22)) throw AssertionError() if (element22 !in 3L .. 1L != !range1.contains(element22)) throw AssertionError() @@ -889,10 +697,10 @@ fun testR1xE22() { fun testR1xE23() { // with possible local optimizations - if (2.toDouble() in 3L .. 1L != range1.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in 3L .. 1L != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in 3L .. 1L) != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in 3L .. 1L) != range1.contains(2.toDouble())) throw AssertionError() + if (4.toLong() in 3L .. 1L != range1.contains(4.toLong())) throw AssertionError() + if (4.toLong() !in 3L .. 1L != !range1.contains(4.toLong())) throw AssertionError() + if (!(4.toLong() in 3L .. 1L) != !range1.contains(4.toLong())) throw AssertionError() + if (!(4.toLong() !in 3L .. 1L) != range1.contains(4.toLong())) throw AssertionError() // no local optimizations if (element23 in 3L .. 1L != range1.contains(element23)) throw AssertionError() if (element23 !in 3L .. 1L != !range1.contains(element23)) throw AssertionError() @@ -900,160 +708,4 @@ fun testR1xE23() { if (!(element23 !in 3L .. 1L) != range1.contains(element23)) throw AssertionError() } -fun testR1xE24() { - // with possible local optimizations - if (3.toByte() in 3L .. 1L != range1.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in 3L .. 1L != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in 3L .. 1L) != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in 3L .. 1L) != range1.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in 3L .. 1L != range1.contains(element24)) throw AssertionError() - if (element24 !in 3L .. 1L != !range1.contains(element24)) throw AssertionError() - if (!(element24 in 3L .. 1L) != !range1.contains(element24)) throw AssertionError() - if (!(element24 !in 3L .. 1L) != range1.contains(element24)) throw AssertionError() -} - -fun testR1xE25() { - // with possible local optimizations - if (3.toShort() in 3L .. 1L != range1.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in 3L .. 1L != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in 3L .. 1L) != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in 3L .. 1L) != range1.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in 3L .. 1L != range1.contains(element25)) throw AssertionError() - if (element25 !in 3L .. 1L != !range1.contains(element25)) throw AssertionError() - if (!(element25 in 3L .. 1L) != !range1.contains(element25)) throw AssertionError() - if (!(element25 !in 3L .. 1L) != range1.contains(element25)) throw AssertionError() -} - -fun testR1xE26() { - // with possible local optimizations - if (3 in 3L .. 1L != range1.contains(3)) throw AssertionError() - if (3 !in 3L .. 1L != !range1.contains(3)) throw AssertionError() - if (!(3 in 3L .. 1L) != !range1.contains(3)) throw AssertionError() - if (!(3 !in 3L .. 1L) != range1.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in 3L .. 1L != range1.contains(element26)) throw AssertionError() - if (element26 !in 3L .. 1L != !range1.contains(element26)) throw AssertionError() - if (!(element26 in 3L .. 1L) != !range1.contains(element26)) throw AssertionError() - if (!(element26 !in 3L .. 1L) != range1.contains(element26)) throw AssertionError() -} - -fun testR1xE27() { - // with possible local optimizations - if (3.toLong() in 3L .. 1L != range1.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in 3L .. 1L != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in 3L .. 1L) != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in 3L .. 1L) != range1.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in 3L .. 1L != range1.contains(element27)) throw AssertionError() - if (element27 !in 3L .. 1L != !range1.contains(element27)) throw AssertionError() - if (!(element27 in 3L .. 1L) != !range1.contains(element27)) throw AssertionError() - if (!(element27 !in 3L .. 1L) != range1.contains(element27)) throw AssertionError() -} - -fun testR1xE28() { - // with possible local optimizations - if (3.toFloat() in 3L .. 1L != range1.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in 3L .. 1L != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in 3L .. 1L) != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in 3L .. 1L) != range1.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in 3L .. 1L != range1.contains(element28)) throw AssertionError() - if (element28 !in 3L .. 1L != !range1.contains(element28)) throw AssertionError() - if (!(element28 in 3L .. 1L) != !range1.contains(element28)) throw AssertionError() - if (!(element28 !in 3L .. 1L) != range1.contains(element28)) throw AssertionError() -} - -fun testR1xE29() { - // with possible local optimizations - if (3.toDouble() in 3L .. 1L != range1.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in 3L .. 1L != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in 3L .. 1L) != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in 3L .. 1L) != range1.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in 3L .. 1L != range1.contains(element29)) throw AssertionError() - if (element29 !in 3L .. 1L != !range1.contains(element29)) throw AssertionError() - if (!(element29 in 3L .. 1L) != !range1.contains(element29)) throw AssertionError() - if (!(element29 !in 3L .. 1L) != range1.contains(element29)) throw AssertionError() -} - -fun testR1xE30() { - // with possible local optimizations - if (4.toByte() in 3L .. 1L != range1.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in 3L .. 1L != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in 3L .. 1L) != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in 3L .. 1L) != range1.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in 3L .. 1L != range1.contains(element30)) throw AssertionError() - if (element30 !in 3L .. 1L != !range1.contains(element30)) throw AssertionError() - if (!(element30 in 3L .. 1L) != !range1.contains(element30)) throw AssertionError() - if (!(element30 !in 3L .. 1L) != range1.contains(element30)) throw AssertionError() -} - -fun testR1xE31() { - // with possible local optimizations - if (4.toShort() in 3L .. 1L != range1.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in 3L .. 1L != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in 3L .. 1L) != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in 3L .. 1L) != range1.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in 3L .. 1L != range1.contains(element31)) throw AssertionError() - if (element31 !in 3L .. 1L != !range1.contains(element31)) throw AssertionError() - if (!(element31 in 3L .. 1L) != !range1.contains(element31)) throw AssertionError() - if (!(element31 !in 3L .. 1L) != range1.contains(element31)) throw AssertionError() -} - -fun testR1xE32() { - // with possible local optimizations - if (4 in 3L .. 1L != range1.contains(4)) throw AssertionError() - if (4 !in 3L .. 1L != !range1.contains(4)) throw AssertionError() - if (!(4 in 3L .. 1L) != !range1.contains(4)) throw AssertionError() - if (!(4 !in 3L .. 1L) != range1.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in 3L .. 1L != range1.contains(element32)) throw AssertionError() - if (element32 !in 3L .. 1L != !range1.contains(element32)) throw AssertionError() - if (!(element32 in 3L .. 1L) != !range1.contains(element32)) throw AssertionError() - if (!(element32 !in 3L .. 1L) != range1.contains(element32)) throw AssertionError() -} - -fun testR1xE33() { - // with possible local optimizations - if (4.toLong() in 3L .. 1L != range1.contains(4.toLong())) throw AssertionError() - if (4.toLong() !in 3L .. 1L != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() in 3L .. 1L) != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() !in 3L .. 1L) != range1.contains(4.toLong())) throw AssertionError() - // no local optimizations - if (element33 in 3L .. 1L != range1.contains(element33)) throw AssertionError() - if (element33 !in 3L .. 1L != !range1.contains(element33)) throw AssertionError() - if (!(element33 in 3L .. 1L) != !range1.contains(element33)) throw AssertionError() - if (!(element33 !in 3L .. 1L) != range1.contains(element33)) throw AssertionError() -} - -fun testR1xE34() { - // with possible local optimizations - if (4.toFloat() in 3L .. 1L != range1.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in 3L .. 1L != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in 3L .. 1L) != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in 3L .. 1L) != range1.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in 3L .. 1L != range1.contains(element34)) throw AssertionError() - if (element34 !in 3L .. 1L != !range1.contains(element34)) throw AssertionError() - if (!(element34 in 3L .. 1L) != !range1.contains(element34)) throw AssertionError() - if (!(element34 !in 3L .. 1L) != range1.contains(element34)) throw AssertionError() -} - -fun testR1xE35() { - // with possible local optimizations - if (4.toDouble() in 3L .. 1L != range1.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in 3L .. 1L != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in 3L .. 1L) != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in 3L .. 1L) != range1.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in 3L .. 1L != range1.contains(element35)) throw AssertionError() - if (element35 !in 3L .. 1L != !range1.contains(element35)) throw AssertionError() - if (!(element35 in 3L .. 1L) != !range1.contains(element35)) throw AssertionError() - if (!(element35 !in 3L .. 1L) != range1.contains(element35)) throw AssertionError() -} - diff --git a/compiler/testData/codegen/box/ranges/contains/generated/longUntil.kt b/compiler/testData/codegen/box/ranges/contains/generated/longUntil.kt index aed6049bff5..40b1e5db35b 100644 --- a/compiler/testData/codegen/box/ranges/contains/generated/longUntil.kt +++ b/compiler/testData/codegen/box/ranges/contains/generated/longUntil.kt @@ -11,38 +11,26 @@ val element0 = (-1).toByte() val element1 = (-1).toShort() val element2 = (-1) val element3 = (-1).toLong() -val element4 = (-1).toFloat() -val element5 = (-1).toDouble() -val element6 = 0.toByte() -val element7 = 0.toShort() -val element8 = 0 -val element9 = 0.toLong() -val element10 = 0.toFloat() -val element11 = 0.toDouble() -val element12 = 1.toByte() -val element13 = 1.toShort() -val element14 = 1 -val element15 = 1.toLong() -val element16 = 1.toFloat() -val element17 = 1.toDouble() -val element18 = 2.toByte() -val element19 = 2.toShort() -val element20 = 2 -val element21 = 2.toLong() -val element22 = 2.toFloat() -val element23 = 2.toDouble() -val element24 = 3.toByte() -val element25 = 3.toShort() -val element26 = 3 -val element27 = 3.toLong() -val element28 = 3.toFloat() -val element29 = 3.toDouble() -val element30 = 4.toByte() -val element31 = 4.toShort() -val element32 = 4 -val element33 = 4.toLong() -val element34 = 4.toFloat() -val element35 = 4.toDouble() +val element4 = 0.toByte() +val element5 = 0.toShort() +val element6 = 0 +val element7 = 0.toLong() +val element8 = 1.toByte() +val element9 = 1.toShort() +val element10 = 1 +val element11 = 1.toLong() +val element12 = 2.toByte() +val element13 = 2.toShort() +val element14 = 2 +val element15 = 2.toLong() +val element16 = 3.toByte() +val element17 = 3.toShort() +val element18 = 3 +val element19 = 3.toLong() +val element20 = 4.toByte() +val element21 = 4.toShort() +val element22 = 4 +val element23 = 4.toLong() fun box(): String { testR0xE0() @@ -69,18 +57,6 @@ fun box(): String { testR0xE21() testR0xE22() testR0xE23() - testR0xE24() - testR0xE25() - testR0xE26() - testR0xE27() - testR0xE28() - testR0xE29() - testR0xE30() - testR0xE31() - testR0xE32() - testR0xE33() - testR0xE34() - testR0xE35() testR1xE0() testR1xE1() testR1xE2() @@ -105,18 +81,6 @@ fun box(): String { testR1xE21() testR1xE22() testR1xE23() - testR1xE24() - testR1xE25() - testR1xE26() - testR1xE27() - testR1xE28() - testR1xE29() - testR1xE30() - testR1xE31() - testR1xE32() - testR1xE33() - testR1xE34() - testR1xE35() return "OK" } @@ -174,10 +138,10 @@ fun testR0xE3() { fun testR0xE4() { // with possible local optimizations - if ((-1).toFloat() in 1L until 3L != range0.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in 1L until 3L != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in 1L until 3L) != !range0.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in 1L until 3L) != range0.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in 1L until 3L != range0.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in 1L until 3L != !range0.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in 1L until 3L) != !range0.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in 1L until 3L) != range0.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in 1L until 3L != range0.contains(element4)) throw AssertionError() if (element4 !in 1L until 3L != !range0.contains(element4)) throw AssertionError() @@ -187,10 +151,10 @@ fun testR0xE4() { fun testR0xE5() { // with possible local optimizations - if ((-1).toDouble() in 1L until 3L != range0.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in 1L until 3L != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in 1L until 3L) != !range0.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in 1L until 3L) != range0.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in 1L until 3L != range0.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in 1L until 3L != !range0.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in 1L until 3L) != !range0.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in 1L until 3L) != range0.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in 1L until 3L != range0.contains(element5)) throw AssertionError() if (element5 !in 1L until 3L != !range0.contains(element5)) throw AssertionError() @@ -200,10 +164,10 @@ fun testR0xE5() { fun testR0xE6() { // with possible local optimizations - if (0.toByte() in 1L until 3L != range0.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in 1L until 3L != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in 1L until 3L) != !range0.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in 1L until 3L) != range0.contains(0.toByte())) throw AssertionError() + if (0 in 1L until 3L != range0.contains(0)) throw AssertionError() + if (0 !in 1L until 3L != !range0.contains(0)) throw AssertionError() + if (!(0 in 1L until 3L) != !range0.contains(0)) throw AssertionError() + if (!(0 !in 1L until 3L) != range0.contains(0)) throw AssertionError() // no local optimizations if (element6 in 1L until 3L != range0.contains(element6)) throw AssertionError() if (element6 !in 1L until 3L != !range0.contains(element6)) throw AssertionError() @@ -213,10 +177,10 @@ fun testR0xE6() { fun testR0xE7() { // with possible local optimizations - if (0.toShort() in 1L until 3L != range0.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in 1L until 3L != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in 1L until 3L) != !range0.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in 1L until 3L) != range0.contains(0.toShort())) throw AssertionError() + if (0.toLong() in 1L until 3L != range0.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in 1L until 3L != !range0.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in 1L until 3L) != !range0.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in 1L until 3L) != range0.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in 1L until 3L != range0.contains(element7)) throw AssertionError() if (element7 !in 1L until 3L != !range0.contains(element7)) throw AssertionError() @@ -226,10 +190,10 @@ fun testR0xE7() { fun testR0xE8() { // with possible local optimizations - if (0 in 1L until 3L != range0.contains(0)) throw AssertionError() - if (0 !in 1L until 3L != !range0.contains(0)) throw AssertionError() - if (!(0 in 1L until 3L) != !range0.contains(0)) throw AssertionError() - if (!(0 !in 1L until 3L) != range0.contains(0)) throw AssertionError() + if (1.toByte() in 1L until 3L != range0.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in 1L until 3L != !range0.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in 1L until 3L) != !range0.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in 1L until 3L) != range0.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in 1L until 3L != range0.contains(element8)) throw AssertionError() if (element8 !in 1L until 3L != !range0.contains(element8)) throw AssertionError() @@ -239,10 +203,10 @@ fun testR0xE8() { fun testR0xE9() { // with possible local optimizations - if (0.toLong() in 1L until 3L != range0.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in 1L until 3L != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in 1L until 3L) != !range0.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in 1L until 3L) != range0.contains(0.toLong())) throw AssertionError() + if (1.toShort() in 1L until 3L != range0.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in 1L until 3L != !range0.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in 1L until 3L) != !range0.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in 1L until 3L) != range0.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in 1L until 3L != range0.contains(element9)) throw AssertionError() if (element9 !in 1L until 3L != !range0.contains(element9)) throw AssertionError() @@ -252,10 +216,10 @@ fun testR0xE9() { fun testR0xE10() { // with possible local optimizations - if (0.toFloat() in 1L until 3L != range0.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in 1L until 3L != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in 1L until 3L) != !range0.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in 1L until 3L) != range0.contains(0.toFloat())) throw AssertionError() + if (1 in 1L until 3L != range0.contains(1)) throw AssertionError() + if (1 !in 1L until 3L != !range0.contains(1)) throw AssertionError() + if (!(1 in 1L until 3L) != !range0.contains(1)) throw AssertionError() + if (!(1 !in 1L until 3L) != range0.contains(1)) throw AssertionError() // no local optimizations if (element10 in 1L until 3L != range0.contains(element10)) throw AssertionError() if (element10 !in 1L until 3L != !range0.contains(element10)) throw AssertionError() @@ -265,10 +229,10 @@ fun testR0xE10() { fun testR0xE11() { // with possible local optimizations - if (0.toDouble() in 1L until 3L != range0.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in 1L until 3L != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in 1L until 3L) != !range0.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in 1L until 3L) != range0.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in 1L until 3L != range0.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in 1L until 3L != !range0.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in 1L until 3L) != !range0.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in 1L until 3L) != range0.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in 1L until 3L != range0.contains(element11)) throw AssertionError() if (element11 !in 1L until 3L != !range0.contains(element11)) throw AssertionError() @@ -278,10 +242,10 @@ fun testR0xE11() { fun testR0xE12() { // with possible local optimizations - if (1.toByte() in 1L until 3L != range0.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in 1L until 3L != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in 1L until 3L) != !range0.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in 1L until 3L) != range0.contains(1.toByte())) throw AssertionError() + if (2.toByte() in 1L until 3L != range0.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in 1L until 3L != !range0.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in 1L until 3L) != !range0.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in 1L until 3L) != range0.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in 1L until 3L != range0.contains(element12)) throw AssertionError() if (element12 !in 1L until 3L != !range0.contains(element12)) throw AssertionError() @@ -291,10 +255,10 @@ fun testR0xE12() { fun testR0xE13() { // with possible local optimizations - if (1.toShort() in 1L until 3L != range0.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in 1L until 3L != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in 1L until 3L) != !range0.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in 1L until 3L) != range0.contains(1.toShort())) throw AssertionError() + if (2.toShort() in 1L until 3L != range0.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in 1L until 3L != !range0.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in 1L until 3L) != !range0.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in 1L until 3L) != range0.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in 1L until 3L != range0.contains(element13)) throw AssertionError() if (element13 !in 1L until 3L != !range0.contains(element13)) throw AssertionError() @@ -304,10 +268,10 @@ fun testR0xE13() { fun testR0xE14() { // with possible local optimizations - if (1 in 1L until 3L != range0.contains(1)) throw AssertionError() - if (1 !in 1L until 3L != !range0.contains(1)) throw AssertionError() - if (!(1 in 1L until 3L) != !range0.contains(1)) throw AssertionError() - if (!(1 !in 1L until 3L) != range0.contains(1)) throw AssertionError() + if (2 in 1L until 3L != range0.contains(2)) throw AssertionError() + if (2 !in 1L until 3L != !range0.contains(2)) throw AssertionError() + if (!(2 in 1L until 3L) != !range0.contains(2)) throw AssertionError() + if (!(2 !in 1L until 3L) != range0.contains(2)) throw AssertionError() // no local optimizations if (element14 in 1L until 3L != range0.contains(element14)) throw AssertionError() if (element14 !in 1L until 3L != !range0.contains(element14)) throw AssertionError() @@ -317,10 +281,10 @@ fun testR0xE14() { fun testR0xE15() { // with possible local optimizations - if (1.toLong() in 1L until 3L != range0.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in 1L until 3L != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in 1L until 3L) != !range0.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in 1L until 3L) != range0.contains(1.toLong())) throw AssertionError() + if (2.toLong() in 1L until 3L != range0.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in 1L until 3L != !range0.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in 1L until 3L) != !range0.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in 1L until 3L) != range0.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in 1L until 3L != range0.contains(element15)) throw AssertionError() if (element15 !in 1L until 3L != !range0.contains(element15)) throw AssertionError() @@ -330,10 +294,10 @@ fun testR0xE15() { fun testR0xE16() { // with possible local optimizations - if (1.toFloat() in 1L until 3L != range0.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in 1L until 3L != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in 1L until 3L) != !range0.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in 1L until 3L) != range0.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in 1L until 3L != range0.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in 1L until 3L != !range0.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in 1L until 3L) != !range0.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in 1L until 3L) != range0.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in 1L until 3L != range0.contains(element16)) throw AssertionError() if (element16 !in 1L until 3L != !range0.contains(element16)) throw AssertionError() @@ -343,10 +307,10 @@ fun testR0xE16() { fun testR0xE17() { // with possible local optimizations - if (1.toDouble() in 1L until 3L != range0.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in 1L until 3L != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in 1L until 3L) != !range0.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in 1L until 3L) != range0.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in 1L until 3L != range0.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in 1L until 3L != !range0.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in 1L until 3L) != !range0.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in 1L until 3L) != range0.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in 1L until 3L != range0.contains(element17)) throw AssertionError() if (element17 !in 1L until 3L != !range0.contains(element17)) throw AssertionError() @@ -356,10 +320,10 @@ fun testR0xE17() { fun testR0xE18() { // with possible local optimizations - if (2.toByte() in 1L until 3L != range0.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in 1L until 3L != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in 1L until 3L) != !range0.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in 1L until 3L) != range0.contains(2.toByte())) throw AssertionError() + if (3 in 1L until 3L != range0.contains(3)) throw AssertionError() + if (3 !in 1L until 3L != !range0.contains(3)) throw AssertionError() + if (!(3 in 1L until 3L) != !range0.contains(3)) throw AssertionError() + if (!(3 !in 1L until 3L) != range0.contains(3)) throw AssertionError() // no local optimizations if (element18 in 1L until 3L != range0.contains(element18)) throw AssertionError() if (element18 !in 1L until 3L != !range0.contains(element18)) throw AssertionError() @@ -369,10 +333,10 @@ fun testR0xE18() { fun testR0xE19() { // with possible local optimizations - if (2.toShort() in 1L until 3L != range0.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in 1L until 3L != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in 1L until 3L) != !range0.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in 1L until 3L) != range0.contains(2.toShort())) throw AssertionError() + if (3.toLong() in 1L until 3L != range0.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in 1L until 3L != !range0.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in 1L until 3L) != !range0.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in 1L until 3L) != range0.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in 1L until 3L != range0.contains(element19)) throw AssertionError() if (element19 !in 1L until 3L != !range0.contains(element19)) throw AssertionError() @@ -382,10 +346,10 @@ fun testR0xE19() { fun testR0xE20() { // with possible local optimizations - if (2 in 1L until 3L != range0.contains(2)) throw AssertionError() - if (2 !in 1L until 3L != !range0.contains(2)) throw AssertionError() - if (!(2 in 1L until 3L) != !range0.contains(2)) throw AssertionError() - if (!(2 !in 1L until 3L) != range0.contains(2)) throw AssertionError() + if (4.toByte() in 1L until 3L != range0.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in 1L until 3L != !range0.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in 1L until 3L) != !range0.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in 1L until 3L) != range0.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in 1L until 3L != range0.contains(element20)) throw AssertionError() if (element20 !in 1L until 3L != !range0.contains(element20)) throw AssertionError() @@ -395,10 +359,10 @@ fun testR0xE20() { fun testR0xE21() { // with possible local optimizations - if (2.toLong() in 1L until 3L != range0.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in 1L until 3L != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in 1L until 3L) != !range0.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in 1L until 3L) != range0.contains(2.toLong())) throw AssertionError() + if (4.toShort() in 1L until 3L != range0.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in 1L until 3L != !range0.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in 1L until 3L) != !range0.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in 1L until 3L) != range0.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in 1L until 3L != range0.contains(element21)) throw AssertionError() if (element21 !in 1L until 3L != !range0.contains(element21)) throw AssertionError() @@ -408,10 +372,10 @@ fun testR0xE21() { fun testR0xE22() { // with possible local optimizations - if (2.toFloat() in 1L until 3L != range0.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in 1L until 3L != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in 1L until 3L) != !range0.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in 1L until 3L) != range0.contains(2.toFloat())) throw AssertionError() + if (4 in 1L until 3L != range0.contains(4)) throw AssertionError() + if (4 !in 1L until 3L != !range0.contains(4)) throw AssertionError() + if (!(4 in 1L until 3L) != !range0.contains(4)) throw AssertionError() + if (!(4 !in 1L until 3L) != range0.contains(4)) throw AssertionError() // no local optimizations if (element22 in 1L until 3L != range0.contains(element22)) throw AssertionError() if (element22 !in 1L until 3L != !range0.contains(element22)) throw AssertionError() @@ -420,172 +384,16 @@ fun testR0xE22() { } fun testR0xE23() { - // with possible local optimizations - if (2.toDouble() in 1L until 3L != range0.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in 1L until 3L != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in 1L until 3L) != !range0.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in 1L until 3L) != range0.contains(2.toDouble())) throw AssertionError() - // no local optimizations - if (element23 in 1L until 3L != range0.contains(element23)) throw AssertionError() - if (element23 !in 1L until 3L != !range0.contains(element23)) throw AssertionError() - if (!(element23 in 1L until 3L) != !range0.contains(element23)) throw AssertionError() - if (!(element23 !in 1L until 3L) != range0.contains(element23)) throw AssertionError() -} - -fun testR0xE24() { - // with possible local optimizations - if (3.toByte() in 1L until 3L != range0.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in 1L until 3L != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in 1L until 3L) != !range0.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in 1L until 3L) != range0.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in 1L until 3L != range0.contains(element24)) throw AssertionError() - if (element24 !in 1L until 3L != !range0.contains(element24)) throw AssertionError() - if (!(element24 in 1L until 3L) != !range0.contains(element24)) throw AssertionError() - if (!(element24 !in 1L until 3L) != range0.contains(element24)) throw AssertionError() -} - -fun testR0xE25() { - // with possible local optimizations - if (3.toShort() in 1L until 3L != range0.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in 1L until 3L != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in 1L until 3L) != !range0.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in 1L until 3L) != range0.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in 1L until 3L != range0.contains(element25)) throw AssertionError() - if (element25 !in 1L until 3L != !range0.contains(element25)) throw AssertionError() - if (!(element25 in 1L until 3L) != !range0.contains(element25)) throw AssertionError() - if (!(element25 !in 1L until 3L) != range0.contains(element25)) throw AssertionError() -} - -fun testR0xE26() { - // with possible local optimizations - if (3 in 1L until 3L != range0.contains(3)) throw AssertionError() - if (3 !in 1L until 3L != !range0.contains(3)) throw AssertionError() - if (!(3 in 1L until 3L) != !range0.contains(3)) throw AssertionError() - if (!(3 !in 1L until 3L) != range0.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in 1L until 3L != range0.contains(element26)) throw AssertionError() - if (element26 !in 1L until 3L != !range0.contains(element26)) throw AssertionError() - if (!(element26 in 1L until 3L) != !range0.contains(element26)) throw AssertionError() - if (!(element26 !in 1L until 3L) != range0.contains(element26)) throw AssertionError() -} - -fun testR0xE27() { - // with possible local optimizations - if (3.toLong() in 1L until 3L != range0.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in 1L until 3L != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in 1L until 3L) != !range0.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in 1L until 3L) != range0.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in 1L until 3L != range0.contains(element27)) throw AssertionError() - if (element27 !in 1L until 3L != !range0.contains(element27)) throw AssertionError() - if (!(element27 in 1L until 3L) != !range0.contains(element27)) throw AssertionError() - if (!(element27 !in 1L until 3L) != range0.contains(element27)) throw AssertionError() -} - -fun testR0xE28() { - // with possible local optimizations - if (3.toFloat() in 1L until 3L != range0.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in 1L until 3L != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in 1L until 3L) != !range0.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in 1L until 3L) != range0.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in 1L until 3L != range0.contains(element28)) throw AssertionError() - if (element28 !in 1L until 3L != !range0.contains(element28)) throw AssertionError() - if (!(element28 in 1L until 3L) != !range0.contains(element28)) throw AssertionError() - if (!(element28 !in 1L until 3L) != range0.contains(element28)) throw AssertionError() -} - -fun testR0xE29() { - // with possible local optimizations - if (3.toDouble() in 1L until 3L != range0.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in 1L until 3L != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in 1L until 3L) != !range0.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in 1L until 3L) != range0.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in 1L until 3L != range0.contains(element29)) throw AssertionError() - if (element29 !in 1L until 3L != !range0.contains(element29)) throw AssertionError() - if (!(element29 in 1L until 3L) != !range0.contains(element29)) throw AssertionError() - if (!(element29 !in 1L until 3L) != range0.contains(element29)) throw AssertionError() -} - -fun testR0xE30() { - // with possible local optimizations - if (4.toByte() in 1L until 3L != range0.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in 1L until 3L != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in 1L until 3L) != !range0.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in 1L until 3L) != range0.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in 1L until 3L != range0.contains(element30)) throw AssertionError() - if (element30 !in 1L until 3L != !range0.contains(element30)) throw AssertionError() - if (!(element30 in 1L until 3L) != !range0.contains(element30)) throw AssertionError() - if (!(element30 !in 1L until 3L) != range0.contains(element30)) throw AssertionError() -} - -fun testR0xE31() { - // with possible local optimizations - if (4.toShort() in 1L until 3L != range0.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in 1L until 3L != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in 1L until 3L) != !range0.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in 1L until 3L) != range0.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in 1L until 3L != range0.contains(element31)) throw AssertionError() - if (element31 !in 1L until 3L != !range0.contains(element31)) throw AssertionError() - if (!(element31 in 1L until 3L) != !range0.contains(element31)) throw AssertionError() - if (!(element31 !in 1L until 3L) != range0.contains(element31)) throw AssertionError() -} - -fun testR0xE32() { - // with possible local optimizations - if (4 in 1L until 3L != range0.contains(4)) throw AssertionError() - if (4 !in 1L until 3L != !range0.contains(4)) throw AssertionError() - if (!(4 in 1L until 3L) != !range0.contains(4)) throw AssertionError() - if (!(4 !in 1L until 3L) != range0.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in 1L until 3L != range0.contains(element32)) throw AssertionError() - if (element32 !in 1L until 3L != !range0.contains(element32)) throw AssertionError() - if (!(element32 in 1L until 3L) != !range0.contains(element32)) throw AssertionError() - if (!(element32 !in 1L until 3L) != range0.contains(element32)) throw AssertionError() -} - -fun testR0xE33() { // with possible local optimizations if (4.toLong() in 1L until 3L != range0.contains(4.toLong())) throw AssertionError() if (4.toLong() !in 1L until 3L != !range0.contains(4.toLong())) throw AssertionError() if (!(4.toLong() in 1L until 3L) != !range0.contains(4.toLong())) throw AssertionError() if (!(4.toLong() !in 1L until 3L) != range0.contains(4.toLong())) throw AssertionError() // no local optimizations - if (element33 in 1L until 3L != range0.contains(element33)) throw AssertionError() - if (element33 !in 1L until 3L != !range0.contains(element33)) throw AssertionError() - if (!(element33 in 1L until 3L) != !range0.contains(element33)) throw AssertionError() - if (!(element33 !in 1L until 3L) != range0.contains(element33)) throw AssertionError() -} - -fun testR0xE34() { - // with possible local optimizations - if (4.toFloat() in 1L until 3L != range0.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in 1L until 3L != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in 1L until 3L) != !range0.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in 1L until 3L) != range0.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in 1L until 3L != range0.contains(element34)) throw AssertionError() - if (element34 !in 1L until 3L != !range0.contains(element34)) throw AssertionError() - if (!(element34 in 1L until 3L) != !range0.contains(element34)) throw AssertionError() - if (!(element34 !in 1L until 3L) != range0.contains(element34)) throw AssertionError() -} - -fun testR0xE35() { - // with possible local optimizations - if (4.toDouble() in 1L until 3L != range0.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in 1L until 3L != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in 1L until 3L) != !range0.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in 1L until 3L) != range0.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in 1L until 3L != range0.contains(element35)) throw AssertionError() - if (element35 !in 1L until 3L != !range0.contains(element35)) throw AssertionError() - if (!(element35 in 1L until 3L) != !range0.contains(element35)) throw AssertionError() - if (!(element35 !in 1L until 3L) != range0.contains(element35)) throw AssertionError() + if (element23 in 1L until 3L != range0.contains(element23)) throw AssertionError() + if (element23 !in 1L until 3L != !range0.contains(element23)) throw AssertionError() + if (!(element23 in 1L until 3L) != !range0.contains(element23)) throw AssertionError() + if (!(element23 !in 1L until 3L) != range0.contains(element23)) throw AssertionError() } fun testR1xE0() { @@ -642,10 +450,10 @@ fun testR1xE3() { fun testR1xE4() { // with possible local optimizations - if ((-1).toFloat() in 3L until 1L != range1.contains((-1).toFloat())) throw AssertionError() - if ((-1).toFloat() !in 3L until 1L != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() in 3L until 1L) != !range1.contains((-1).toFloat())) throw AssertionError() - if (!((-1).toFloat() !in 3L until 1L) != range1.contains((-1).toFloat())) throw AssertionError() + if (0.toByte() in 3L until 1L != range1.contains(0.toByte())) throw AssertionError() + if (0.toByte() !in 3L until 1L != !range1.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() in 3L until 1L) != !range1.contains(0.toByte())) throw AssertionError() + if (!(0.toByte() !in 3L until 1L) != range1.contains(0.toByte())) throw AssertionError() // no local optimizations if (element4 in 3L until 1L != range1.contains(element4)) throw AssertionError() if (element4 !in 3L until 1L != !range1.contains(element4)) throw AssertionError() @@ -655,10 +463,10 @@ fun testR1xE4() { fun testR1xE5() { // with possible local optimizations - if ((-1).toDouble() in 3L until 1L != range1.contains((-1).toDouble())) throw AssertionError() - if ((-1).toDouble() !in 3L until 1L != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() in 3L until 1L) != !range1.contains((-1).toDouble())) throw AssertionError() - if (!((-1).toDouble() !in 3L until 1L) != range1.contains((-1).toDouble())) throw AssertionError() + if (0.toShort() in 3L until 1L != range1.contains(0.toShort())) throw AssertionError() + if (0.toShort() !in 3L until 1L != !range1.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() in 3L until 1L) != !range1.contains(0.toShort())) throw AssertionError() + if (!(0.toShort() !in 3L until 1L) != range1.contains(0.toShort())) throw AssertionError() // no local optimizations if (element5 in 3L until 1L != range1.contains(element5)) throw AssertionError() if (element5 !in 3L until 1L != !range1.contains(element5)) throw AssertionError() @@ -668,10 +476,10 @@ fun testR1xE5() { fun testR1xE6() { // with possible local optimizations - if (0.toByte() in 3L until 1L != range1.contains(0.toByte())) throw AssertionError() - if (0.toByte() !in 3L until 1L != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() in 3L until 1L) != !range1.contains(0.toByte())) throw AssertionError() - if (!(0.toByte() !in 3L until 1L) != range1.contains(0.toByte())) throw AssertionError() + if (0 in 3L until 1L != range1.contains(0)) throw AssertionError() + if (0 !in 3L until 1L != !range1.contains(0)) throw AssertionError() + if (!(0 in 3L until 1L) != !range1.contains(0)) throw AssertionError() + if (!(0 !in 3L until 1L) != range1.contains(0)) throw AssertionError() // no local optimizations if (element6 in 3L until 1L != range1.contains(element6)) throw AssertionError() if (element6 !in 3L until 1L != !range1.contains(element6)) throw AssertionError() @@ -681,10 +489,10 @@ fun testR1xE6() { fun testR1xE7() { // with possible local optimizations - if (0.toShort() in 3L until 1L != range1.contains(0.toShort())) throw AssertionError() - if (0.toShort() !in 3L until 1L != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() in 3L until 1L) != !range1.contains(0.toShort())) throw AssertionError() - if (!(0.toShort() !in 3L until 1L) != range1.contains(0.toShort())) throw AssertionError() + if (0.toLong() in 3L until 1L != range1.contains(0.toLong())) throw AssertionError() + if (0.toLong() !in 3L until 1L != !range1.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() in 3L until 1L) != !range1.contains(0.toLong())) throw AssertionError() + if (!(0.toLong() !in 3L until 1L) != range1.contains(0.toLong())) throw AssertionError() // no local optimizations if (element7 in 3L until 1L != range1.contains(element7)) throw AssertionError() if (element7 !in 3L until 1L != !range1.contains(element7)) throw AssertionError() @@ -694,10 +502,10 @@ fun testR1xE7() { fun testR1xE8() { // with possible local optimizations - if (0 in 3L until 1L != range1.contains(0)) throw AssertionError() - if (0 !in 3L until 1L != !range1.contains(0)) throw AssertionError() - if (!(0 in 3L until 1L) != !range1.contains(0)) throw AssertionError() - if (!(0 !in 3L until 1L) != range1.contains(0)) throw AssertionError() + if (1.toByte() in 3L until 1L != range1.contains(1.toByte())) throw AssertionError() + if (1.toByte() !in 3L until 1L != !range1.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() in 3L until 1L) != !range1.contains(1.toByte())) throw AssertionError() + if (!(1.toByte() !in 3L until 1L) != range1.contains(1.toByte())) throw AssertionError() // no local optimizations if (element8 in 3L until 1L != range1.contains(element8)) throw AssertionError() if (element8 !in 3L until 1L != !range1.contains(element8)) throw AssertionError() @@ -707,10 +515,10 @@ fun testR1xE8() { fun testR1xE9() { // with possible local optimizations - if (0.toLong() in 3L until 1L != range1.contains(0.toLong())) throw AssertionError() - if (0.toLong() !in 3L until 1L != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() in 3L until 1L) != !range1.contains(0.toLong())) throw AssertionError() - if (!(0.toLong() !in 3L until 1L) != range1.contains(0.toLong())) throw AssertionError() + if (1.toShort() in 3L until 1L != range1.contains(1.toShort())) throw AssertionError() + if (1.toShort() !in 3L until 1L != !range1.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() in 3L until 1L) != !range1.contains(1.toShort())) throw AssertionError() + if (!(1.toShort() !in 3L until 1L) != range1.contains(1.toShort())) throw AssertionError() // no local optimizations if (element9 in 3L until 1L != range1.contains(element9)) throw AssertionError() if (element9 !in 3L until 1L != !range1.contains(element9)) throw AssertionError() @@ -720,10 +528,10 @@ fun testR1xE9() { fun testR1xE10() { // with possible local optimizations - if (0.toFloat() in 3L until 1L != range1.contains(0.toFloat())) throw AssertionError() - if (0.toFloat() !in 3L until 1L != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() in 3L until 1L) != !range1.contains(0.toFloat())) throw AssertionError() - if (!(0.toFloat() !in 3L until 1L) != range1.contains(0.toFloat())) throw AssertionError() + if (1 in 3L until 1L != range1.contains(1)) throw AssertionError() + if (1 !in 3L until 1L != !range1.contains(1)) throw AssertionError() + if (!(1 in 3L until 1L) != !range1.contains(1)) throw AssertionError() + if (!(1 !in 3L until 1L) != range1.contains(1)) throw AssertionError() // no local optimizations if (element10 in 3L until 1L != range1.contains(element10)) throw AssertionError() if (element10 !in 3L until 1L != !range1.contains(element10)) throw AssertionError() @@ -733,10 +541,10 @@ fun testR1xE10() { fun testR1xE11() { // with possible local optimizations - if (0.toDouble() in 3L until 1L != range1.contains(0.toDouble())) throw AssertionError() - if (0.toDouble() !in 3L until 1L != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() in 3L until 1L) != !range1.contains(0.toDouble())) throw AssertionError() - if (!(0.toDouble() !in 3L until 1L) != range1.contains(0.toDouble())) throw AssertionError() + if (1.toLong() in 3L until 1L != range1.contains(1.toLong())) throw AssertionError() + if (1.toLong() !in 3L until 1L != !range1.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() in 3L until 1L) != !range1.contains(1.toLong())) throw AssertionError() + if (!(1.toLong() !in 3L until 1L) != range1.contains(1.toLong())) throw AssertionError() // no local optimizations if (element11 in 3L until 1L != range1.contains(element11)) throw AssertionError() if (element11 !in 3L until 1L != !range1.contains(element11)) throw AssertionError() @@ -746,10 +554,10 @@ fun testR1xE11() { fun testR1xE12() { // with possible local optimizations - if (1.toByte() in 3L until 1L != range1.contains(1.toByte())) throw AssertionError() - if (1.toByte() !in 3L until 1L != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() in 3L until 1L) != !range1.contains(1.toByte())) throw AssertionError() - if (!(1.toByte() !in 3L until 1L) != range1.contains(1.toByte())) throw AssertionError() + if (2.toByte() in 3L until 1L != range1.contains(2.toByte())) throw AssertionError() + if (2.toByte() !in 3L until 1L != !range1.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() in 3L until 1L) != !range1.contains(2.toByte())) throw AssertionError() + if (!(2.toByte() !in 3L until 1L) != range1.contains(2.toByte())) throw AssertionError() // no local optimizations if (element12 in 3L until 1L != range1.contains(element12)) throw AssertionError() if (element12 !in 3L until 1L != !range1.contains(element12)) throw AssertionError() @@ -759,10 +567,10 @@ fun testR1xE12() { fun testR1xE13() { // with possible local optimizations - if (1.toShort() in 3L until 1L != range1.contains(1.toShort())) throw AssertionError() - if (1.toShort() !in 3L until 1L != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() in 3L until 1L) != !range1.contains(1.toShort())) throw AssertionError() - if (!(1.toShort() !in 3L until 1L) != range1.contains(1.toShort())) throw AssertionError() + if (2.toShort() in 3L until 1L != range1.contains(2.toShort())) throw AssertionError() + if (2.toShort() !in 3L until 1L != !range1.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() in 3L until 1L) != !range1.contains(2.toShort())) throw AssertionError() + if (!(2.toShort() !in 3L until 1L) != range1.contains(2.toShort())) throw AssertionError() // no local optimizations if (element13 in 3L until 1L != range1.contains(element13)) throw AssertionError() if (element13 !in 3L until 1L != !range1.contains(element13)) throw AssertionError() @@ -772,10 +580,10 @@ fun testR1xE13() { fun testR1xE14() { // with possible local optimizations - if (1 in 3L until 1L != range1.contains(1)) throw AssertionError() - if (1 !in 3L until 1L != !range1.contains(1)) throw AssertionError() - if (!(1 in 3L until 1L) != !range1.contains(1)) throw AssertionError() - if (!(1 !in 3L until 1L) != range1.contains(1)) throw AssertionError() + if (2 in 3L until 1L != range1.contains(2)) throw AssertionError() + if (2 !in 3L until 1L != !range1.contains(2)) throw AssertionError() + if (!(2 in 3L until 1L) != !range1.contains(2)) throw AssertionError() + if (!(2 !in 3L until 1L) != range1.contains(2)) throw AssertionError() // no local optimizations if (element14 in 3L until 1L != range1.contains(element14)) throw AssertionError() if (element14 !in 3L until 1L != !range1.contains(element14)) throw AssertionError() @@ -785,10 +593,10 @@ fun testR1xE14() { fun testR1xE15() { // with possible local optimizations - if (1.toLong() in 3L until 1L != range1.contains(1.toLong())) throw AssertionError() - if (1.toLong() !in 3L until 1L != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() in 3L until 1L) != !range1.contains(1.toLong())) throw AssertionError() - if (!(1.toLong() !in 3L until 1L) != range1.contains(1.toLong())) throw AssertionError() + if (2.toLong() in 3L until 1L != range1.contains(2.toLong())) throw AssertionError() + if (2.toLong() !in 3L until 1L != !range1.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() in 3L until 1L) != !range1.contains(2.toLong())) throw AssertionError() + if (!(2.toLong() !in 3L until 1L) != range1.contains(2.toLong())) throw AssertionError() // no local optimizations if (element15 in 3L until 1L != range1.contains(element15)) throw AssertionError() if (element15 !in 3L until 1L != !range1.contains(element15)) throw AssertionError() @@ -798,10 +606,10 @@ fun testR1xE15() { fun testR1xE16() { // with possible local optimizations - if (1.toFloat() in 3L until 1L != range1.contains(1.toFloat())) throw AssertionError() - if (1.toFloat() !in 3L until 1L != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() in 3L until 1L) != !range1.contains(1.toFloat())) throw AssertionError() - if (!(1.toFloat() !in 3L until 1L) != range1.contains(1.toFloat())) throw AssertionError() + if (3.toByte() in 3L until 1L != range1.contains(3.toByte())) throw AssertionError() + if (3.toByte() !in 3L until 1L != !range1.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() in 3L until 1L) != !range1.contains(3.toByte())) throw AssertionError() + if (!(3.toByte() !in 3L until 1L) != range1.contains(3.toByte())) throw AssertionError() // no local optimizations if (element16 in 3L until 1L != range1.contains(element16)) throw AssertionError() if (element16 !in 3L until 1L != !range1.contains(element16)) throw AssertionError() @@ -811,10 +619,10 @@ fun testR1xE16() { fun testR1xE17() { // with possible local optimizations - if (1.toDouble() in 3L until 1L != range1.contains(1.toDouble())) throw AssertionError() - if (1.toDouble() !in 3L until 1L != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() in 3L until 1L) != !range1.contains(1.toDouble())) throw AssertionError() - if (!(1.toDouble() !in 3L until 1L) != range1.contains(1.toDouble())) throw AssertionError() + if (3.toShort() in 3L until 1L != range1.contains(3.toShort())) throw AssertionError() + if (3.toShort() !in 3L until 1L != !range1.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() in 3L until 1L) != !range1.contains(3.toShort())) throw AssertionError() + if (!(3.toShort() !in 3L until 1L) != range1.contains(3.toShort())) throw AssertionError() // no local optimizations if (element17 in 3L until 1L != range1.contains(element17)) throw AssertionError() if (element17 !in 3L until 1L != !range1.contains(element17)) throw AssertionError() @@ -824,10 +632,10 @@ fun testR1xE17() { fun testR1xE18() { // with possible local optimizations - if (2.toByte() in 3L until 1L != range1.contains(2.toByte())) throw AssertionError() - if (2.toByte() !in 3L until 1L != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() in 3L until 1L) != !range1.contains(2.toByte())) throw AssertionError() - if (!(2.toByte() !in 3L until 1L) != range1.contains(2.toByte())) throw AssertionError() + if (3 in 3L until 1L != range1.contains(3)) throw AssertionError() + if (3 !in 3L until 1L != !range1.contains(3)) throw AssertionError() + if (!(3 in 3L until 1L) != !range1.contains(3)) throw AssertionError() + if (!(3 !in 3L until 1L) != range1.contains(3)) throw AssertionError() // no local optimizations if (element18 in 3L until 1L != range1.contains(element18)) throw AssertionError() if (element18 !in 3L until 1L != !range1.contains(element18)) throw AssertionError() @@ -837,10 +645,10 @@ fun testR1xE18() { fun testR1xE19() { // with possible local optimizations - if (2.toShort() in 3L until 1L != range1.contains(2.toShort())) throw AssertionError() - if (2.toShort() !in 3L until 1L != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() in 3L until 1L) != !range1.contains(2.toShort())) throw AssertionError() - if (!(2.toShort() !in 3L until 1L) != range1.contains(2.toShort())) throw AssertionError() + if (3.toLong() in 3L until 1L != range1.contains(3.toLong())) throw AssertionError() + if (3.toLong() !in 3L until 1L != !range1.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() in 3L until 1L) != !range1.contains(3.toLong())) throw AssertionError() + if (!(3.toLong() !in 3L until 1L) != range1.contains(3.toLong())) throw AssertionError() // no local optimizations if (element19 in 3L until 1L != range1.contains(element19)) throw AssertionError() if (element19 !in 3L until 1L != !range1.contains(element19)) throw AssertionError() @@ -850,10 +658,10 @@ fun testR1xE19() { fun testR1xE20() { // with possible local optimizations - if (2 in 3L until 1L != range1.contains(2)) throw AssertionError() - if (2 !in 3L until 1L != !range1.contains(2)) throw AssertionError() - if (!(2 in 3L until 1L) != !range1.contains(2)) throw AssertionError() - if (!(2 !in 3L until 1L) != range1.contains(2)) throw AssertionError() + if (4.toByte() in 3L until 1L != range1.contains(4.toByte())) throw AssertionError() + if (4.toByte() !in 3L until 1L != !range1.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() in 3L until 1L) != !range1.contains(4.toByte())) throw AssertionError() + if (!(4.toByte() !in 3L until 1L) != range1.contains(4.toByte())) throw AssertionError() // no local optimizations if (element20 in 3L until 1L != range1.contains(element20)) throw AssertionError() if (element20 !in 3L until 1L != !range1.contains(element20)) throw AssertionError() @@ -863,10 +671,10 @@ fun testR1xE20() { fun testR1xE21() { // with possible local optimizations - if (2.toLong() in 3L until 1L != range1.contains(2.toLong())) throw AssertionError() - if (2.toLong() !in 3L until 1L != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() in 3L until 1L) != !range1.contains(2.toLong())) throw AssertionError() - if (!(2.toLong() !in 3L until 1L) != range1.contains(2.toLong())) throw AssertionError() + if (4.toShort() in 3L until 1L != range1.contains(4.toShort())) throw AssertionError() + if (4.toShort() !in 3L until 1L != !range1.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() in 3L until 1L) != !range1.contains(4.toShort())) throw AssertionError() + if (!(4.toShort() !in 3L until 1L) != range1.contains(4.toShort())) throw AssertionError() // no local optimizations if (element21 in 3L until 1L != range1.contains(element21)) throw AssertionError() if (element21 !in 3L until 1L != !range1.contains(element21)) throw AssertionError() @@ -876,10 +684,10 @@ fun testR1xE21() { fun testR1xE22() { // with possible local optimizations - if (2.toFloat() in 3L until 1L != range1.contains(2.toFloat())) throw AssertionError() - if (2.toFloat() !in 3L until 1L != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() in 3L until 1L) != !range1.contains(2.toFloat())) throw AssertionError() - if (!(2.toFloat() !in 3L until 1L) != range1.contains(2.toFloat())) throw AssertionError() + if (4 in 3L until 1L != range1.contains(4)) throw AssertionError() + if (4 !in 3L until 1L != !range1.contains(4)) throw AssertionError() + if (!(4 in 3L until 1L) != !range1.contains(4)) throw AssertionError() + if (!(4 !in 3L until 1L) != range1.contains(4)) throw AssertionError() // no local optimizations if (element22 in 3L until 1L != range1.contains(element22)) throw AssertionError() if (element22 !in 3L until 1L != !range1.contains(element22)) throw AssertionError() @@ -889,10 +697,10 @@ fun testR1xE22() { fun testR1xE23() { // with possible local optimizations - if (2.toDouble() in 3L until 1L != range1.contains(2.toDouble())) throw AssertionError() - if (2.toDouble() !in 3L until 1L != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() in 3L until 1L) != !range1.contains(2.toDouble())) throw AssertionError() - if (!(2.toDouble() !in 3L until 1L) != range1.contains(2.toDouble())) throw AssertionError() + if (4.toLong() in 3L until 1L != range1.contains(4.toLong())) throw AssertionError() + if (4.toLong() !in 3L until 1L != !range1.contains(4.toLong())) throw AssertionError() + if (!(4.toLong() in 3L until 1L) != !range1.contains(4.toLong())) throw AssertionError() + if (!(4.toLong() !in 3L until 1L) != range1.contains(4.toLong())) throw AssertionError() // no local optimizations if (element23 in 3L until 1L != range1.contains(element23)) throw AssertionError() if (element23 !in 3L until 1L != !range1.contains(element23)) throw AssertionError() @@ -900,160 +708,4 @@ fun testR1xE23() { if (!(element23 !in 3L until 1L) != range1.contains(element23)) throw AssertionError() } -fun testR1xE24() { - // with possible local optimizations - if (3.toByte() in 3L until 1L != range1.contains(3.toByte())) throw AssertionError() - if (3.toByte() !in 3L until 1L != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() in 3L until 1L) != !range1.contains(3.toByte())) throw AssertionError() - if (!(3.toByte() !in 3L until 1L) != range1.contains(3.toByte())) throw AssertionError() - // no local optimizations - if (element24 in 3L until 1L != range1.contains(element24)) throw AssertionError() - if (element24 !in 3L until 1L != !range1.contains(element24)) throw AssertionError() - if (!(element24 in 3L until 1L) != !range1.contains(element24)) throw AssertionError() - if (!(element24 !in 3L until 1L) != range1.contains(element24)) throw AssertionError() -} - -fun testR1xE25() { - // with possible local optimizations - if (3.toShort() in 3L until 1L != range1.contains(3.toShort())) throw AssertionError() - if (3.toShort() !in 3L until 1L != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() in 3L until 1L) != !range1.contains(3.toShort())) throw AssertionError() - if (!(3.toShort() !in 3L until 1L) != range1.contains(3.toShort())) throw AssertionError() - // no local optimizations - if (element25 in 3L until 1L != range1.contains(element25)) throw AssertionError() - if (element25 !in 3L until 1L != !range1.contains(element25)) throw AssertionError() - if (!(element25 in 3L until 1L) != !range1.contains(element25)) throw AssertionError() - if (!(element25 !in 3L until 1L) != range1.contains(element25)) throw AssertionError() -} - -fun testR1xE26() { - // with possible local optimizations - if (3 in 3L until 1L != range1.contains(3)) throw AssertionError() - if (3 !in 3L until 1L != !range1.contains(3)) throw AssertionError() - if (!(3 in 3L until 1L) != !range1.contains(3)) throw AssertionError() - if (!(3 !in 3L until 1L) != range1.contains(3)) throw AssertionError() - // no local optimizations - if (element26 in 3L until 1L != range1.contains(element26)) throw AssertionError() - if (element26 !in 3L until 1L != !range1.contains(element26)) throw AssertionError() - if (!(element26 in 3L until 1L) != !range1.contains(element26)) throw AssertionError() - if (!(element26 !in 3L until 1L) != range1.contains(element26)) throw AssertionError() -} - -fun testR1xE27() { - // with possible local optimizations - if (3.toLong() in 3L until 1L != range1.contains(3.toLong())) throw AssertionError() - if (3.toLong() !in 3L until 1L != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() in 3L until 1L) != !range1.contains(3.toLong())) throw AssertionError() - if (!(3.toLong() !in 3L until 1L) != range1.contains(3.toLong())) throw AssertionError() - // no local optimizations - if (element27 in 3L until 1L != range1.contains(element27)) throw AssertionError() - if (element27 !in 3L until 1L != !range1.contains(element27)) throw AssertionError() - if (!(element27 in 3L until 1L) != !range1.contains(element27)) throw AssertionError() - if (!(element27 !in 3L until 1L) != range1.contains(element27)) throw AssertionError() -} - -fun testR1xE28() { - // with possible local optimizations - if (3.toFloat() in 3L until 1L != range1.contains(3.toFloat())) throw AssertionError() - if (3.toFloat() !in 3L until 1L != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() in 3L until 1L) != !range1.contains(3.toFloat())) throw AssertionError() - if (!(3.toFloat() !in 3L until 1L) != range1.contains(3.toFloat())) throw AssertionError() - // no local optimizations - if (element28 in 3L until 1L != range1.contains(element28)) throw AssertionError() - if (element28 !in 3L until 1L != !range1.contains(element28)) throw AssertionError() - if (!(element28 in 3L until 1L) != !range1.contains(element28)) throw AssertionError() - if (!(element28 !in 3L until 1L) != range1.contains(element28)) throw AssertionError() -} - -fun testR1xE29() { - // with possible local optimizations - if (3.toDouble() in 3L until 1L != range1.contains(3.toDouble())) throw AssertionError() - if (3.toDouble() !in 3L until 1L != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() in 3L until 1L) != !range1.contains(3.toDouble())) throw AssertionError() - if (!(3.toDouble() !in 3L until 1L) != range1.contains(3.toDouble())) throw AssertionError() - // no local optimizations - if (element29 in 3L until 1L != range1.contains(element29)) throw AssertionError() - if (element29 !in 3L until 1L != !range1.contains(element29)) throw AssertionError() - if (!(element29 in 3L until 1L) != !range1.contains(element29)) throw AssertionError() - if (!(element29 !in 3L until 1L) != range1.contains(element29)) throw AssertionError() -} - -fun testR1xE30() { - // with possible local optimizations - if (4.toByte() in 3L until 1L != range1.contains(4.toByte())) throw AssertionError() - if (4.toByte() !in 3L until 1L != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() in 3L until 1L) != !range1.contains(4.toByte())) throw AssertionError() - if (!(4.toByte() !in 3L until 1L) != range1.contains(4.toByte())) throw AssertionError() - // no local optimizations - if (element30 in 3L until 1L != range1.contains(element30)) throw AssertionError() - if (element30 !in 3L until 1L != !range1.contains(element30)) throw AssertionError() - if (!(element30 in 3L until 1L) != !range1.contains(element30)) throw AssertionError() - if (!(element30 !in 3L until 1L) != range1.contains(element30)) throw AssertionError() -} - -fun testR1xE31() { - // with possible local optimizations - if (4.toShort() in 3L until 1L != range1.contains(4.toShort())) throw AssertionError() - if (4.toShort() !in 3L until 1L != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() in 3L until 1L) != !range1.contains(4.toShort())) throw AssertionError() - if (!(4.toShort() !in 3L until 1L) != range1.contains(4.toShort())) throw AssertionError() - // no local optimizations - if (element31 in 3L until 1L != range1.contains(element31)) throw AssertionError() - if (element31 !in 3L until 1L != !range1.contains(element31)) throw AssertionError() - if (!(element31 in 3L until 1L) != !range1.contains(element31)) throw AssertionError() - if (!(element31 !in 3L until 1L) != range1.contains(element31)) throw AssertionError() -} - -fun testR1xE32() { - // with possible local optimizations - if (4 in 3L until 1L != range1.contains(4)) throw AssertionError() - if (4 !in 3L until 1L != !range1.contains(4)) throw AssertionError() - if (!(4 in 3L until 1L) != !range1.contains(4)) throw AssertionError() - if (!(4 !in 3L until 1L) != range1.contains(4)) throw AssertionError() - // no local optimizations - if (element32 in 3L until 1L != range1.contains(element32)) throw AssertionError() - if (element32 !in 3L until 1L != !range1.contains(element32)) throw AssertionError() - if (!(element32 in 3L until 1L) != !range1.contains(element32)) throw AssertionError() - if (!(element32 !in 3L until 1L) != range1.contains(element32)) throw AssertionError() -} - -fun testR1xE33() { - // with possible local optimizations - if (4.toLong() in 3L until 1L != range1.contains(4.toLong())) throw AssertionError() - if (4.toLong() !in 3L until 1L != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() in 3L until 1L) != !range1.contains(4.toLong())) throw AssertionError() - if (!(4.toLong() !in 3L until 1L) != range1.contains(4.toLong())) throw AssertionError() - // no local optimizations - if (element33 in 3L until 1L != range1.contains(element33)) throw AssertionError() - if (element33 !in 3L until 1L != !range1.contains(element33)) throw AssertionError() - if (!(element33 in 3L until 1L) != !range1.contains(element33)) throw AssertionError() - if (!(element33 !in 3L until 1L) != range1.contains(element33)) throw AssertionError() -} - -fun testR1xE34() { - // with possible local optimizations - if (4.toFloat() in 3L until 1L != range1.contains(4.toFloat())) throw AssertionError() - if (4.toFloat() !in 3L until 1L != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() in 3L until 1L) != !range1.contains(4.toFloat())) throw AssertionError() - if (!(4.toFloat() !in 3L until 1L) != range1.contains(4.toFloat())) throw AssertionError() - // no local optimizations - if (element34 in 3L until 1L != range1.contains(element34)) throw AssertionError() - if (element34 !in 3L until 1L != !range1.contains(element34)) throw AssertionError() - if (!(element34 in 3L until 1L) != !range1.contains(element34)) throw AssertionError() - if (!(element34 !in 3L until 1L) != range1.contains(element34)) throw AssertionError() -} - -fun testR1xE35() { - // with possible local optimizations - if (4.toDouble() in 3L until 1L != range1.contains(4.toDouble())) throw AssertionError() - if (4.toDouble() !in 3L until 1L != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() in 3L until 1L) != !range1.contains(4.toDouble())) throw AssertionError() - if (!(4.toDouble() !in 3L until 1L) != range1.contains(4.toDouble())) throw AssertionError() - // no local optimizations - if (element35 in 3L until 1L != range1.contains(element35)) throw AssertionError() - if (element35 !in 3L until 1L != !range1.contains(element35)) throw AssertionError() - if (!(element35 in 3L until 1L) != !range1.contains(element35)) throw AssertionError() - if (!(element35 !in 3L until 1L) != range1.contains(element35)) throw AssertionError() -} - diff --git a/compiler/testData/codegen/box/ranges/contains/inRangeWithNonmatchingArguments.kt b/compiler/testData/codegen/box/ranges/contains/inRangeWithNonmatchingArguments.kt index afd2d675855..e9bef793ec5 100644 --- a/compiler/testData/codegen/box/ranges/contains/inRangeWithNonmatchingArguments.kt +++ b/compiler/testData/codegen/box/ranges/contains/inRangeWithNonmatchingArguments.kt @@ -9,9 +9,9 @@ fun box(): String { assert(Long.MAX_VALUE !in Int.MIN_VALUE..Int.MAX_VALUE) assert(Int.MAX_VALUE in Long.MIN_VALUE..Long.MAX_VALUE) assert(Double.MAX_VALUE !in Float.MIN_VALUE..Float.MAX_VALUE) - assert(Float.MIN_VALUE in 0..1) - assert(2.0 !in 1..0) - assert(1.0f in 0L..2L) + assert(Float.MIN_VALUE in 0.0..1.0) + assert(2.0 !in 1.0f..0.0f) + assert(1L in 0..2) return "OK" } diff --git a/compiler/testData/codegen/bytecodeText/ranges/inNonMatchingRangeNotIntrinsified.kt b/compiler/testData/codegen/bytecodeText/ranges/inNonMatchingRangeNotIntrinsified.kt deleted file mode 100644 index d96085a9fb5..00000000000 --- a/compiler/testData/codegen/bytecodeText/ranges/inNonMatchingRangeNotIntrinsified.kt +++ /dev/null @@ -1,20 +0,0 @@ -fun byteInFloat(x: Byte, a: Float, b: Float) = x in a .. b -fun byteInDouble(x: Byte, a: Double, b: Double) = x in a .. b -fun shortInFloat(x: Short, a: Float, b: Float) = x in a .. b -fun shortInDouble(x: Short, a: Double, b: Double) = x in a .. b -fun intInFloat(x: Int, a: Float, b: Float) = x in a .. b -fun intInDouble(x: Int, a: Double, b: Double) = x in a .. b -fun longInFloat(x: Long, a: Float, b: Float) = x in a .. b -fun longInDouble(x: Long, a: Double, b: Double) = x in a .. b -fun floatInInt(x: Float, a: Int, b: Int) = x in a .. b -fun floatInLong(x: Float, a: Long, b: Long) = x in a .. b -fun doubleInInt(x: Double, a: Int, b: Int) = x in a .. b -fun doubleInLong(x: Double, a: Long, b: Long) = x in a .. b - -// 4 INVOKESPECIAL -// 4 NEW -// 8 rangeTo -// 2 longRangeContains -// 2 intRangeContains -// 4 doubleRangeContains -// 4 floatRangeContains diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/BytecodeTextTestGenerated.java b/compiler/tests/org/jetbrains/kotlin/codegen/BytecodeTextTestGenerated.java index 6afd474b698..05bfcb7be31 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/BytecodeTextTestGenerated.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/BytecodeTextTestGenerated.java @@ -4167,11 +4167,6 @@ public class BytecodeTextTestGenerated extends AbstractBytecodeTextTest { runTest("compiler/testData/codegen/bytecodeText/ranges/inNonMatchingRangeIntrinsified.kt"); } - @TestMetadata("inNonMatchingRangeNotIntrinsified.kt") - public void testInNonMatchingRangeNotIntrinsified() throws Exception { - runTest("compiler/testData/codegen/bytecodeText/ranges/inNonMatchingRangeNotIntrinsified.kt"); - } - @TestMetadata("inOptimizableRange.kt") public void testInOptimizableRange() throws Exception { runTest("compiler/testData/codegen/bytecodeText/ranges/inOptimizableRange.kt"); diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/ir/IrBytecodeTextTestGenerated.java b/compiler/tests/org/jetbrains/kotlin/codegen/ir/IrBytecodeTextTestGenerated.java index 3cc34422512..3cb4f6f6d0b 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/ir/IrBytecodeTextTestGenerated.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/ir/IrBytecodeTextTestGenerated.java @@ -4125,11 +4125,6 @@ public class IrBytecodeTextTestGenerated extends AbstractIrBytecodeTextTest { runTest("compiler/testData/codegen/bytecodeText/ranges/inNonMatchingRangeIntrinsified.kt"); } - @TestMetadata("inNonMatchingRangeNotIntrinsified.kt") - public void testInNonMatchingRangeNotIntrinsified() throws Exception { - runTest("compiler/testData/codegen/bytecodeText/ranges/inNonMatchingRangeNotIntrinsified.kt"); - } - @TestMetadata("inOptimizableRange.kt") public void testInOptimizableRange() throws Exception { runTest("compiler/testData/codegen/bytecodeText/ranges/inOptimizableRange.kt"); diff --git a/compiler/tests/org/jetbrains/kotlin/generators/tests/GenerateInRangeExpressionTestData.kt b/compiler/tests/org/jetbrains/kotlin/generators/tests/GenerateInRangeExpressionTestData.kt index f55b381dc58..a395a59e644 100644 --- a/compiler/tests/org/jetbrains/kotlin/generators/tests/GenerateInRangeExpressionTestData.kt +++ b/compiler/tests/org/jetbrains/kotlin/generators/tests/GenerateInRangeExpressionTestData.kt @@ -119,9 +119,13 @@ object GenerateInRangeExpressionTestData { val charLiterals = listOf("'0'", "'1'", "'2'", "'3'", "'4'") - val numericLiterals = + val integerLiterals = listOf("(-1)", "0", "1", "2", "3", "4").flatMap { - listOf("$it.toByte()", "$it.toShort()", it, "$it.toLong()", "$it.toFloat()", "$it.toDouble()") + listOf("$it.toByte()", "$it.toShort()", it, "$it.toLong()") + } + val floatingPointLiterals = + listOf("(-1)", "0", "1", "2", "3", "4").flatMap { + listOf("$it.toFloat()", "$it.toDouble()") } generateRangeOperatorTestCase( @@ -151,14 +155,14 @@ object GenerateInRangeExpressionTestData { "1", "..", "3", - numericLiterals + integerLiterals ) generateRangeOperatorTestCase( "intUntil.kt", "1", "until", "3", - numericLiterals + integerLiterals ) generateRangeOperatorTestCase( "intDownTo.kt", @@ -173,14 +177,14 @@ object GenerateInRangeExpressionTestData { "1L", "..", "3L", - numericLiterals + integerLiterals ) generateRangeOperatorTestCase( "longUntil.kt", "1L", "until", "3L", - numericLiterals + integerLiterals ) generateRangeOperatorTestCase( "longDownTo.kt", @@ -195,7 +199,7 @@ object GenerateInRangeExpressionTestData { "1.0F", "..", "3.0F", - numericLiterals + floatingPointLiterals ) generateRangeOperatorTestCase( @@ -203,13 +207,13 @@ object GenerateInRangeExpressionTestData { "1.0", "..", "3.0", - numericLiterals + floatingPointLiterals ) generateMatrixTestCase( "arrayIndices.kt", listOf("intArray.indices", "objectArray.indices", "emptyIntArray.indices", "emptyObjectArray.indices"), - numericLiterals, + integerLiterals, """val intArray = intArrayOf(1, 2, 3) |val objectArray = arrayOf(1, 2, 3) |val emptyIntArray = intArrayOf() @@ -220,7 +224,7 @@ object GenerateInRangeExpressionTestData { generateMatrixTestCase( "collectionIndices.kt", listOf("collection.indices", "emptyCollection.indices"), - numericLiterals, + integerLiterals, """val collection = listOf(1, 2, 3) |val emptyCollection = listOf() """.trimMargin() @@ -229,7 +233,7 @@ object GenerateInRangeExpressionTestData { generateMatrixTestCase( "charSequenceIndices.kt", listOf("charSequence.indices", "emptyCharSequence.indices"), - numericLiterals, + integerLiterals, """val charSequence: CharSequence = "123" |val emptyCharSequence: CharSequence = "" """.trimMargin() diff --git a/idea/src/org/jetbrains/kotlin/idea/inspections/ConvertTwoComparisonsToRangeCheckInspection.kt b/idea/src/org/jetbrains/kotlin/idea/inspections/ConvertTwoComparisonsToRangeCheckInspection.kt index d9d36d1d444..25d4303081e 100644 --- a/idea/src/org/jetbrains/kotlin/idea/inspections/ConvertTwoComparisonsToRangeCheckInspection.kt +++ b/idea/src/org/jetbrains/kotlin/idea/inspections/ConvertTwoComparisonsToRangeCheckInspection.kt @@ -156,6 +156,8 @@ class ConvertTwoComparisonsToRangeCheckInspection : if (valType.isPrimitiveNumberType() && minType.isPrimitiveNumberType() && maxType.isPrimitiveNumberType()) { //char is comparable to chars only if (KotlinBuiltIns.isChar(valType) || KotlinBuiltIns.isChar(minType) || KotlinBuiltIns.isChar(maxType)) return null + //floating point ranges can't contain integer types and vise versa + if (valType.isInteger() && (minType.isFloatingPoint() || maxType.isFloatingPoint())) return null if (valType.isFloatingPoint()) { if (minType.isInteger()) diff --git a/idea/testData/inspectionsLocal/convertTwoComparisonsToRangeCheck/double.kt b/idea/testData/inspectionsLocal/convertTwoComparisonsToRangeCheck/double.kt index b5c27b418a9..c6bc03b42e5 100644 --- a/idea/testData/inspectionsLocal/convertTwoComparisonsToRangeCheck/double.kt +++ b/idea/testData/inspectionsLocal/convertTwoComparisonsToRangeCheck/double.kt @@ -1,4 +1,5 @@ // WITH_RUNTIME +// PROBLEM: none fun foo(bar: Int) { bar >= 0.0 && 10.0 >= bar } \ No newline at end of file diff --git a/idea/testData/inspectionsLocal/convertTwoComparisonsToRangeCheck/double.kt.after b/idea/testData/inspectionsLocal/convertTwoComparisonsToRangeCheck/double.kt.after deleted file mode 100644 index a1215d16d6e..00000000000 --- a/idea/testData/inspectionsLocal/convertTwoComparisonsToRangeCheck/double.kt.after +++ /dev/null @@ -1,4 +0,0 @@ -// WITH_RUNTIME -fun foo(bar: Int) { - bar in 0.0..10.0 -} \ No newline at end of file diff --git a/libraries/stdlib/api/js-v1/kotlin.ranges.kt b/libraries/stdlib/api/js-v1/kotlin.ranges.kt index 4f58da0897c..648a5be6d51 100644 --- a/libraries/stdlib/api/js-v1/kotlin.ranges.kt +++ b/libraries/stdlib/api/js-v1/kotlin.ranges.kt @@ -113,11 +113,11 @@ public inline operator fun > @kotlin.internal.InlineOnly public inline operator fun kotlin.ranges.CharRange.contains(element: kotlin.Char?): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "byteRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Double): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "byteRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Float): kotlin.Boolean @@ -130,52 +130,52 @@ public operator fun kotlin.ranges.ClosedRange.contains(value: kotli @kotlin.jvm.JvmName(name = "byteRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Short): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "doubleRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Byte): kotlin.Boolean @kotlin.jvm.JvmName(name = "doubleRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Float): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "doubleRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Int): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "doubleRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Long): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "doubleRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Short): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "floatRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Byte): kotlin.Boolean @kotlin.jvm.JvmName(name = "floatRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Double): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "floatRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Int): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "floatRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Long): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "floatRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Short): kotlin.Boolean @kotlin.jvm.JvmName(name = "intRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Byte): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "intRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Double): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "intRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Float): kotlin.Boolean @@ -188,11 +188,11 @@ public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin @kotlin.jvm.JvmName(name = "longRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Byte): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "longRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Double): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "longRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Float): kotlin.Boolean @@ -205,11 +205,11 @@ public operator fun kotlin.ranges.ClosedRange.contains(value: kotli @kotlin.jvm.JvmName(name = "shortRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Byte): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "shortRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Double): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "shortRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Float): kotlin.Boolean diff --git a/libraries/stdlib/api/js/kotlin.ranges.kt b/libraries/stdlib/api/js/kotlin.ranges.kt index 3a6351040c4..46df3217170 100644 --- a/libraries/stdlib/api/js/kotlin.ranges.kt +++ b/libraries/stdlib/api/js/kotlin.ranges.kt @@ -113,11 +113,11 @@ public inline operator fun > @kotlin.internal.InlineOnly public inline operator fun kotlin.ranges.CharRange.contains(element: kotlin.Char?): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "byteRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Double): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "byteRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Float): kotlin.Boolean @@ -130,52 +130,52 @@ public operator fun kotlin.ranges.ClosedRange.contains(value: kotli @kotlin.jvm.JvmName(name = "byteRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Short): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "doubleRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Byte): kotlin.Boolean @kotlin.jvm.JvmName(name = "doubleRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Float): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "doubleRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Int): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "doubleRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Long): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "doubleRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Short): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "floatRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Byte): kotlin.Boolean @kotlin.jvm.JvmName(name = "floatRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Double): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "floatRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Int): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "floatRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Long): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "floatRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Short): kotlin.Boolean @kotlin.jvm.JvmName(name = "intRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Byte): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "intRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Double): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "intRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Float): kotlin.Boolean @@ -188,11 +188,11 @@ public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin @kotlin.jvm.JvmName(name = "longRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Byte): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "longRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Double): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "longRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Float): kotlin.Boolean @@ -205,11 +205,11 @@ public operator fun kotlin.ranges.ClosedRange.contains(value: kotli @kotlin.jvm.JvmName(name = "shortRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Byte): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "shortRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Double): kotlin.Boolean -@kotlin.Deprecated(message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@kotlin.Deprecated(level = DeprecationLevel.ERROR, message = "This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") @kotlin.jvm.JvmName(name = "shortRangeContains") public operator fun kotlin.ranges.ClosedRange.contains(value: kotlin.Float): kotlin.Boolean diff --git a/libraries/stdlib/common/src/generated/_Ranges.kt b/libraries/stdlib/common/src/generated/_Ranges.kt index 9fabafca3e8..dbcda7d95d5 100644 --- a/libraries/stdlib/common/src/generated/_Ranges.kt +++ b/libraries/stdlib/common/src/generated/_Ranges.kt @@ -213,7 +213,7 @@ public operator fun ClosedRange.contains(value: Byte): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("doubleRangeContains") public operator fun ClosedRange.contains(value: Byte): Boolean { return contains(value.toDouble()) @@ -222,7 +222,7 @@ public operator fun ClosedRange.contains(value: Byte): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("floatRangeContains") public operator fun ClosedRange.contains(value: Byte): Boolean { return contains(value.toFloat()) @@ -231,7 +231,7 @@ public operator fun ClosedRange.contains(value: Byte): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("intRangeContains") public operator fun ClosedRange.contains(value: Double): Boolean { return value.toIntExactOrNull().let { if (it != null) contains(it) else false } @@ -240,7 +240,7 @@ public operator fun ClosedRange.contains(value: Double): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("longRangeContains") public operator fun ClosedRange.contains(value: Double): Boolean { return value.toLongExactOrNull().let { if (it != null) contains(it) else false } @@ -249,7 +249,7 @@ public operator fun ClosedRange.contains(value: Double): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("byteRangeContains") public operator fun ClosedRange.contains(value: Double): Boolean { return value.toByteExactOrNull().let { if (it != null) contains(it) else false } @@ -258,7 +258,7 @@ public operator fun ClosedRange.contains(value: Double): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("shortRangeContains") public operator fun ClosedRange.contains(value: Double): Boolean { return value.toShortExactOrNull().let { if (it != null) contains(it) else false } @@ -275,7 +275,7 @@ public operator fun ClosedRange.contains(value: Double): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("intRangeContains") public operator fun ClosedRange.contains(value: Float): Boolean { return value.toIntExactOrNull().let { if (it != null) contains(it) else false } @@ -284,7 +284,7 @@ public operator fun ClosedRange.contains(value: Float): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("longRangeContains") public operator fun ClosedRange.contains(value: Float): Boolean { return value.toLongExactOrNull().let { if (it != null) contains(it) else false } @@ -293,7 +293,7 @@ public operator fun ClosedRange.contains(value: Float): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("byteRangeContains") public operator fun ClosedRange.contains(value: Float): Boolean { return value.toByteExactOrNull().let { if (it != null) contains(it) else false } @@ -302,7 +302,7 @@ public operator fun ClosedRange.contains(value: Float): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("shortRangeContains") public operator fun ClosedRange.contains(value: Float): Boolean { return value.toShortExactOrNull().let { if (it != null) contains(it) else false } @@ -343,7 +343,7 @@ public operator fun ClosedRange.contains(value: Int): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("doubleRangeContains") public operator fun ClosedRange.contains(value: Int): Boolean { return contains(value.toDouble()) @@ -352,7 +352,7 @@ public operator fun ClosedRange.contains(value: Int): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("floatRangeContains") public operator fun ClosedRange.contains(value: Int): Boolean { return contains(value.toFloat()) @@ -385,7 +385,7 @@ public operator fun ClosedRange.contains(value: Long): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("doubleRangeContains") public operator fun ClosedRange.contains(value: Long): Boolean { return contains(value.toDouble()) @@ -394,7 +394,7 @@ public operator fun ClosedRange.contains(value: Long): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("floatRangeContains") public operator fun ClosedRange.contains(value: Long): Boolean { return contains(value.toFloat()) @@ -427,7 +427,7 @@ public operator fun ClosedRange.contains(value: Short): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("doubleRangeContains") public operator fun ClosedRange.contains(value: Short): Boolean { return contains(value.toDouble()) @@ -436,7 +436,7 @@ public operator fun ClosedRange.contains(value: Short): Boolean { /** * Checks if the specified [value] belongs to this range. */ -@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.") +@Deprecated("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR) @kotlin.jvm.JvmName("floatRangeContains") public operator fun ClosedRange.contains(value: Short): Boolean { return contains(value.toFloat()) diff --git a/libraries/stdlib/test/ranges/RangeTest.kt b/libraries/stdlib/test/ranges/RangeTest.kt index ebd65d11da6..f2408eaf8ca 100644 --- a/libraries/stdlib/test/ranges/RangeTest.kt +++ b/libraries/stdlib/test/ranges/RangeTest.kt @@ -31,7 +31,7 @@ public class RangeTest { assertTrue(1.toShort() in range) assertTrue(1.toByte() in range) assertTrue(1.toLong() in range) - run @Suppress("DEPRECATION") { + run @Suppress("DEPRECATION_ERROR") { assertTrue(1.toFloat() in range) assertTrue(1.toDouble() in range) } @@ -70,7 +70,7 @@ public class RangeTest { assertTrue(1.toShort() in range) assertTrue(1.toInt() in range) assertTrue(1.toLong() in range) - run @Suppress("DEPRECATION") { + run @Suppress("DEPRECATION_ERROR") { assertTrue(1.toFloat() in range) assertTrue(1.toDouble() in range) } @@ -108,7 +108,7 @@ public class RangeTest { assertTrue(1.toByte() in range) assertTrue(1.toInt() in range) assertTrue(1.toLong() in range) - run @Suppress("DEPRECATION") { + run @Suppress("DEPRECATION_ERROR") { assertTrue(1.toFloat() in range) assertTrue(1.toDouble() in range) } @@ -148,7 +148,7 @@ public class RangeTest { assertTrue(1.toByte() in range) assertTrue(1.toShort() in range) assertTrue(1.toInt() in range) - run @Suppress("DEPRECATION") { + run @Suppress("DEPRECATION_ERROR") { assertTrue(1.toFloat() in range) assertTrue(1.toDouble() in range) @@ -218,7 +218,7 @@ public class RangeTest { assertFalse(range.isEmpty()) - run @Suppress("DEPRECATION") { + run @Suppress("DEPRECATION_ERROR") { assertTrue(1.toByte() in range) assertTrue(1.toShort() in range) assertTrue(1.toInt() in range) @@ -266,7 +266,7 @@ public class RangeTest { assertFalse(range.isEmpty()) - run @Suppress("DEPRECATION") { + run @Suppress("DEPRECATION_ERROR") { assertTrue(1.toByte() in range) assertTrue(1.toShort() in range) assertTrue(1.toInt() in range) diff --git a/libraries/tools/kotlin-stdlib-gen/src/templates/Ranges.kt b/libraries/tools/kotlin-stdlib-gen/src/templates/Ranges.kt index 2aad7dcdbbe..44f7c29572d 100644 --- a/libraries/tools/kotlin-stdlib-gen/src/templates/Ranges.kt +++ b/libraries/tools/kotlin-stdlib-gen/src/templates/Ranges.kt @@ -159,7 +159,7 @@ object RangeOps : TemplateGroupBase() { check(rangeType.isNumeric() == itemType.isNumeric()) { "Required rangeType and itemType both to be numeric or both not, got: $rangeType, $itemType" } if (rangeType.isIntegral() != itemType.isIntegral()) { - deprecate(Deprecation("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.WARNING)) + deprecate(Deprecation("This `contains` operation mixing integer and floating point arguments has ambiguous semantics and is going to be removed.", level = DeprecationLevel.ERROR)) } platformName("${rangeType.name.decapitalize()}RangeContains")