From 6a673a03e4937d49622bac07b4cdcb94755c3d50 Mon Sep 17 00:00:00 2001 From: Dmitry Petrov Date: Wed, 12 Jul 2017 11:56:03 +0300 Subject: [PATCH] Generate test data for in-expression tests, fix bug with indices --- .../codegen/range/ArrayIndicesRangeValue.kt | 2 +- .../range/CharSequenceIndicesRangeValue.kt | 2 +- .../range/CollectionIndicesRangeValue.kt | 2 +- .../ranges/contains/generated/arrayIndices.kt | 2071 +++++++++++++++++ .../ranges/contains/generated/charDownTo.kt | 159 ++ .../contains/generated/charRangeLiteral.kt | 159 ++ .../contains/generated/charSequenceIndices.kt | 1059 +++++++++ .../ranges/contains/generated/charUntil.kt | 159 ++ .../contains/generated/collectionIndices.kt | 1059 +++++++++ .../contains/generated/doubleRangeLiteral.kt | 1058 +++++++++ .../contains/generated/floatRangeLiteral.kt | 1058 +++++++++ .../ranges/contains/generated/intDownTo.kt | 43 + .../contains/generated/intRangeLiteral.kt | 1058 +++++++++ .../box/ranges/contains/generated/intUntil.kt | 1058 +++++++++ .../ranges/contains/generated/longDownTo.kt | 43 + .../contains/generated/longRangeLiteral.kt | 1058 +++++++++ .../ranges/contains/generated/longUntil.kt | 1058 +++++++++ .../box/ranges/contains/inArrayIndices.kt | 21 - .../ranges/contains/inCharSequenceIndices.kt | 16 - .../ranges/contains/inCollectionIndices.kt | 16 - .../ir/IrBlackBoxCodegenTestGenerated.java | 111 +- .../codegen/BlackBoxCodegenTestGenerated.java | 111 +- .../LightAnalysisModeTestGenerated.java | 111 +- .../GenerateInRangeExpressionTestData.kt | 176 ++ .../semantics/JsCodegenBoxTestGenerated.java | 111 +- 25 files changed, 11651 insertions(+), 128 deletions(-) create mode 100644 compiler/testData/codegen/box/ranges/contains/generated/arrayIndices.kt create mode 100644 compiler/testData/codegen/box/ranges/contains/generated/charDownTo.kt create mode 100644 compiler/testData/codegen/box/ranges/contains/generated/charRangeLiteral.kt create mode 100644 compiler/testData/codegen/box/ranges/contains/generated/charSequenceIndices.kt create mode 100644 compiler/testData/codegen/box/ranges/contains/generated/charUntil.kt create mode 100644 compiler/testData/codegen/box/ranges/contains/generated/collectionIndices.kt create mode 100644 compiler/testData/codegen/box/ranges/contains/generated/doubleRangeLiteral.kt create mode 100644 compiler/testData/codegen/box/ranges/contains/generated/floatRangeLiteral.kt create mode 100644 compiler/testData/codegen/box/ranges/contains/generated/intDownTo.kt create mode 100644 compiler/testData/codegen/box/ranges/contains/generated/intRangeLiteral.kt create mode 100644 compiler/testData/codegen/box/ranges/contains/generated/intUntil.kt create mode 100644 compiler/testData/codegen/box/ranges/contains/generated/longDownTo.kt create mode 100644 compiler/testData/codegen/box/ranges/contains/generated/longRangeLiteral.kt create mode 100644 compiler/testData/codegen/box/ranges/contains/generated/longUntil.kt delete mode 100644 compiler/testData/codegen/box/ranges/contains/inArrayIndices.kt delete mode 100644 compiler/testData/codegen/box/ranges/contains/inCharSequenceIndices.kt delete mode 100644 compiler/testData/codegen/box/ranges/contains/inCollectionIndices.kt create mode 100644 generators/src/org/jetbrains/kotlin/generators/tests/GenerateInRangeExpressionTestData.kt diff --git a/compiler/backend/src/org/jetbrains/kotlin/codegen/range/ArrayIndicesRangeValue.kt b/compiler/backend/src/org/jetbrains/kotlin/codegen/range/ArrayIndicesRangeValue.kt index 168acae1c71..75075b9af26 100644 --- a/compiler/backend/src/org/jetbrains/kotlin/codegen/range/ArrayIndicesRangeValue.kt +++ b/compiler/backend/src/org/jetbrains/kotlin/codegen/range/ArrayIndicesRangeValue.kt @@ -31,7 +31,7 @@ class ArrayIndicesRangeValue(rangeCall: ResolvedCall): P private val expectedReceiverType: KotlinType = ExpressionCodegen.getExpectedReceiverType(rangeCall) override fun getBoundedValue(codegen: ExpressionCodegen) = - object : AbstractBoundedValue(codegen, rangeCall) { + object : AbstractBoundedValue(codegen, rangeCall, isHighInclusive = false) { override fun putHighLow(v: InstructionAdapter, type: Type) { codegen.generateCallReceiver(rangeCall).put(codegen.asmType(expectedReceiverType), v) v.arraylength() diff --git a/compiler/backend/src/org/jetbrains/kotlin/codegen/range/CharSequenceIndicesRangeValue.kt b/compiler/backend/src/org/jetbrains/kotlin/codegen/range/CharSequenceIndicesRangeValue.kt index f5892c8126e..10d72245643 100644 --- a/compiler/backend/src/org/jetbrains/kotlin/codegen/range/CharSequenceIndicesRangeValue.kt +++ b/compiler/backend/src/org/jetbrains/kotlin/codegen/range/CharSequenceIndicesRangeValue.kt @@ -31,7 +31,7 @@ class CharSequenceIndicesRangeValue(rangeCall: ResolvedCall() + +val range0 = intArray.indices +val range1 = objectArray.indices +val range2 = emptyIntArray.indices +val range3 = emptyObjectArray.indices + +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() + +fun box(): String { + testR0xE0() + testR0xE1() + testR0xE2() + testR0xE3() + testR0xE4() + testR0xE5() + testR0xE6() + testR0xE7() + testR0xE8() + 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() + testR1xE3() + testR1xE4() + testR1xE5() + testR1xE6() + testR1xE7() + testR1xE8() + 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() + testR2xE0() + testR2xE1() + testR2xE2() + testR2xE3() + testR2xE4() + testR2xE5() + testR2xE6() + testR2xE7() + testR2xE8() + testR2xE9() + testR2xE10() + testR2xE11() + testR2xE12() + testR2xE13() + testR2xE14() + testR2xE15() + testR2xE16() + testR2xE17() + testR2xE18() + testR2xE19() + testR2xE20() + testR2xE21() + testR2xE22() + testR2xE23() + testR2xE24() + testR2xE25() + testR2xE26() + testR2xE27() + testR2xE28() + testR2xE29() + testR2xE30() + testR2xE31() + testR2xE32() + testR2xE33() + testR2xE34() + testR2xE35() + testR3xE0() + testR3xE1() + testR3xE2() + testR3xE3() + testR3xE4() + testR3xE5() + testR3xE6() + testR3xE7() + testR3xE8() + testR3xE9() + testR3xE10() + testR3xE11() + testR3xE12() + testR3xE13() + testR3xE14() + testR3xE15() + testR3xE16() + testR3xE17() + testR3xE18() + testR3xE19() + testR3xE20() + testR3xE21() + testR3xE22() + testR3xE23() + testR3xE24() + testR3xE25() + testR3xE26() + testR3xE27() + testR3xE28() + testR3xE29() + testR3xE30() + testR3xE31() + testR3xE32() + testR3xE33() + testR3xE34() + testR3xE35() + return "OK" +} + +fun testR0xE0() { + // 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() + // no local optimizations + if (element0 in intArray.indices != range0.contains(element0)) throw AssertionError() + if (element0 !in intArray.indices != !range0.contains(element0)) throw AssertionError() + if (!(element0 in intArray.indices) != !range0.contains(element0)) throw AssertionError() + if (!(element0 !in intArray.indices) != range0.contains(element0)) throw AssertionError() +} + +fun testR0xE1() { + // 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() + // no local optimizations + if (element1 in intArray.indices != range0.contains(element1)) throw AssertionError() + if (element1 !in intArray.indices != !range0.contains(element1)) throw AssertionError() + if (!(element1 in intArray.indices) != !range0.contains(element1)) throw AssertionError() + if (!(element1 !in intArray.indices) != range0.contains(element1)) throw AssertionError() +} + +fun testR0xE2() { + // 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() + // no local optimizations + if (element2 in intArray.indices != range0.contains(element2)) throw AssertionError() + if (element2 !in intArray.indices != !range0.contains(element2)) throw AssertionError() + if (!(element2 in intArray.indices) != !range0.contains(element2)) throw AssertionError() + if (!(element2 !in intArray.indices) != range0.contains(element2)) throw AssertionError() +} + +fun testR0xE3() { + // 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() + // no local optimizations + if (element3 in intArray.indices != range0.contains(element3)) throw AssertionError() + if (element3 !in intArray.indices != !range0.contains(element3)) throw AssertionError() + if (!(element3 in intArray.indices) != !range0.contains(element3)) throw AssertionError() + if (!(element3 !in intArray.indices) != range0.contains(element3)) throw AssertionError() +} + +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() + // no local optimizations + if (element4 in intArray.indices != range0.contains(element4)) throw AssertionError() + if (element4 !in intArray.indices != !range0.contains(element4)) throw AssertionError() + if (!(element4 in intArray.indices) != !range0.contains(element4)) throw AssertionError() + if (!(element4 !in intArray.indices) != range0.contains(element4)) throw AssertionError() +} + +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() + // no local optimizations + if (element5 in intArray.indices != range0.contains(element5)) throw AssertionError() + if (element5 !in intArray.indices != !range0.contains(element5)) throw AssertionError() + if (!(element5 in intArray.indices) != !range0.contains(element5)) throw AssertionError() + if (!(element5 !in intArray.indices) != range0.contains(element5)) throw AssertionError() +} + +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() + // no local optimizations + if (element6 in intArray.indices != range0.contains(element6)) throw AssertionError() + if (element6 !in intArray.indices != !range0.contains(element6)) throw AssertionError() + if (!(element6 in intArray.indices) != !range0.contains(element6)) throw AssertionError() + if (!(element6 !in intArray.indices) != range0.contains(element6)) throw AssertionError() +} + +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() + // no local optimizations + if (element7 in intArray.indices != range0.contains(element7)) throw AssertionError() + if (element7 !in intArray.indices != !range0.contains(element7)) throw AssertionError() + if (!(element7 in intArray.indices) != !range0.contains(element7)) throw AssertionError() + if (!(element7 !in intArray.indices) != range0.contains(element7)) throw AssertionError() +} + +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() + // no local optimizations + if (element8 in intArray.indices != range0.contains(element8)) throw AssertionError() + if (element8 !in intArray.indices != !range0.contains(element8)) throw AssertionError() + if (!(element8 in intArray.indices) != !range0.contains(element8)) throw AssertionError() + if (!(element8 !in intArray.indices) != range0.contains(element8)) throw AssertionError() +} + +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() + // no local optimizations + if (element9 in intArray.indices != range0.contains(element9)) throw AssertionError() + if (element9 !in intArray.indices != !range0.contains(element9)) throw AssertionError() + if (!(element9 in intArray.indices) != !range0.contains(element9)) throw AssertionError() + if (!(element9 !in intArray.indices) != range0.contains(element9)) throw AssertionError() +} + +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() + // no local optimizations + if (element10 in intArray.indices != range0.contains(element10)) throw AssertionError() + if (element10 !in intArray.indices != !range0.contains(element10)) throw AssertionError() + if (!(element10 in intArray.indices) != !range0.contains(element10)) throw AssertionError() + if (!(element10 !in intArray.indices) != range0.contains(element10)) throw AssertionError() +} + +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() + // no local optimizations + if (element11 in intArray.indices != range0.contains(element11)) throw AssertionError() + if (element11 !in intArray.indices != !range0.contains(element11)) throw AssertionError() + if (!(element11 in intArray.indices) != !range0.contains(element11)) throw AssertionError() + if (!(element11 !in intArray.indices) != range0.contains(element11)) throw AssertionError() +} + +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() + // no local optimizations + if (element12 in intArray.indices != range0.contains(element12)) throw AssertionError() + if (element12 !in intArray.indices != !range0.contains(element12)) throw AssertionError() + if (!(element12 in intArray.indices) != !range0.contains(element12)) throw AssertionError() + if (!(element12 !in intArray.indices) != range0.contains(element12)) throw AssertionError() +} + +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() + // no local optimizations + if (element13 in intArray.indices != range0.contains(element13)) throw AssertionError() + if (element13 !in intArray.indices != !range0.contains(element13)) throw AssertionError() + if (!(element13 in intArray.indices) != !range0.contains(element13)) throw AssertionError() + if (!(element13 !in intArray.indices) != range0.contains(element13)) throw AssertionError() +} + +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() + // no local optimizations + if (element14 in intArray.indices != range0.contains(element14)) throw AssertionError() + if (element14 !in intArray.indices != !range0.contains(element14)) throw AssertionError() + if (!(element14 in intArray.indices) != !range0.contains(element14)) throw AssertionError() + if (!(element14 !in intArray.indices) != range0.contains(element14)) throw AssertionError() +} + +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() + // no local optimizations + if (element15 in intArray.indices != range0.contains(element15)) throw AssertionError() + if (element15 !in intArray.indices != !range0.contains(element15)) throw AssertionError() + if (!(element15 in intArray.indices) != !range0.contains(element15)) throw AssertionError() + if (!(element15 !in intArray.indices) != range0.contains(element15)) throw AssertionError() +} + +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() + // no local optimizations + if (element16 in intArray.indices != range0.contains(element16)) throw AssertionError() + if (element16 !in intArray.indices != !range0.contains(element16)) throw AssertionError() + if (!(element16 in intArray.indices) != !range0.contains(element16)) throw AssertionError() + if (!(element16 !in intArray.indices) != range0.contains(element16)) throw AssertionError() +} + +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() + // no local optimizations + if (element17 in intArray.indices != range0.contains(element17)) throw AssertionError() + if (element17 !in intArray.indices != !range0.contains(element17)) throw AssertionError() + if (!(element17 in intArray.indices) != !range0.contains(element17)) throw AssertionError() + if (!(element17 !in intArray.indices) != range0.contains(element17)) throw AssertionError() +} + +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() + // no local optimizations + if (element18 in intArray.indices != range0.contains(element18)) throw AssertionError() + if (element18 !in intArray.indices != !range0.contains(element18)) throw AssertionError() + if (!(element18 in intArray.indices) != !range0.contains(element18)) throw AssertionError() + if (!(element18 !in intArray.indices) != range0.contains(element18)) throw AssertionError() +} + +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() + // no local optimizations + if (element19 in intArray.indices != range0.contains(element19)) throw AssertionError() + if (element19 !in intArray.indices != !range0.contains(element19)) throw AssertionError() + if (!(element19 in intArray.indices) != !range0.contains(element19)) throw AssertionError() + if (!(element19 !in intArray.indices) != range0.contains(element19)) throw AssertionError() +} + +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() + // no local optimizations + if (element20 in intArray.indices != range0.contains(element20)) throw AssertionError() + if (element20 !in intArray.indices != !range0.contains(element20)) throw AssertionError() + if (!(element20 in intArray.indices) != !range0.contains(element20)) throw AssertionError() + if (!(element20 !in intArray.indices) != range0.contains(element20)) throw AssertionError() +} + +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() + // no local optimizations + if (element21 in intArray.indices != range0.contains(element21)) throw AssertionError() + if (element21 !in intArray.indices != !range0.contains(element21)) throw AssertionError() + if (!(element21 in intArray.indices) != !range0.contains(element21)) throw AssertionError() + if (!(element21 !in intArray.indices) != range0.contains(element21)) throw AssertionError() +} + +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() + // no local optimizations + if (element22 in intArray.indices != range0.contains(element22)) throw AssertionError() + if (element22 !in intArray.indices != !range0.contains(element22)) throw AssertionError() + if (!(element22 in intArray.indices) != !range0.contains(element22)) throw AssertionError() + if (!(element22 !in intArray.indices) != range0.contains(element22)) throw AssertionError() +} + +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() +} + +fun testR1xE0() { + // 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() + // no local optimizations + if (element0 in objectArray.indices != range1.contains(element0)) throw AssertionError() + if (element0 !in objectArray.indices != !range1.contains(element0)) throw AssertionError() + if (!(element0 in objectArray.indices) != !range1.contains(element0)) throw AssertionError() + if (!(element0 !in objectArray.indices) != range1.contains(element0)) throw AssertionError() +} + +fun testR1xE1() { + // 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() + // no local optimizations + if (element1 in objectArray.indices != range1.contains(element1)) throw AssertionError() + if (element1 !in objectArray.indices != !range1.contains(element1)) throw AssertionError() + if (!(element1 in objectArray.indices) != !range1.contains(element1)) throw AssertionError() + if (!(element1 !in objectArray.indices) != range1.contains(element1)) throw AssertionError() +} + +fun testR1xE2() { + // 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() + // no local optimizations + if (element2 in objectArray.indices != range1.contains(element2)) throw AssertionError() + if (element2 !in objectArray.indices != !range1.contains(element2)) throw AssertionError() + if (!(element2 in objectArray.indices) != !range1.contains(element2)) throw AssertionError() + if (!(element2 !in objectArray.indices) != range1.contains(element2)) throw AssertionError() +} + +fun testR1xE3() { + // 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() + // no local optimizations + if (element3 in objectArray.indices != range1.contains(element3)) throw AssertionError() + if (element3 !in objectArray.indices != !range1.contains(element3)) throw AssertionError() + if (!(element3 in objectArray.indices) != !range1.contains(element3)) throw AssertionError() + if (!(element3 !in objectArray.indices) != range1.contains(element3)) throw AssertionError() +} + +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() + // no local optimizations + if (element4 in objectArray.indices != range1.contains(element4)) throw AssertionError() + if (element4 !in objectArray.indices != !range1.contains(element4)) throw AssertionError() + if (!(element4 in objectArray.indices) != !range1.contains(element4)) throw AssertionError() + if (!(element4 !in objectArray.indices) != range1.contains(element4)) throw AssertionError() +} + +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() + // no local optimizations + if (element5 in objectArray.indices != range1.contains(element5)) throw AssertionError() + if (element5 !in objectArray.indices != !range1.contains(element5)) throw AssertionError() + if (!(element5 in objectArray.indices) != !range1.contains(element5)) throw AssertionError() + if (!(element5 !in objectArray.indices) != range1.contains(element5)) throw AssertionError() +} + +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() + // no local optimizations + if (element6 in objectArray.indices != range1.contains(element6)) throw AssertionError() + if (element6 !in objectArray.indices != !range1.contains(element6)) throw AssertionError() + if (!(element6 in objectArray.indices) != !range1.contains(element6)) throw AssertionError() + if (!(element6 !in objectArray.indices) != range1.contains(element6)) throw AssertionError() +} + +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() + // no local optimizations + if (element7 in objectArray.indices != range1.contains(element7)) throw AssertionError() + if (element7 !in objectArray.indices != !range1.contains(element7)) throw AssertionError() + if (!(element7 in objectArray.indices) != !range1.contains(element7)) throw AssertionError() + if (!(element7 !in objectArray.indices) != range1.contains(element7)) throw AssertionError() +} + +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() + // no local optimizations + if (element8 in objectArray.indices != range1.contains(element8)) throw AssertionError() + if (element8 !in objectArray.indices != !range1.contains(element8)) throw AssertionError() + if (!(element8 in objectArray.indices) != !range1.contains(element8)) throw AssertionError() + if (!(element8 !in objectArray.indices) != range1.contains(element8)) throw AssertionError() +} + +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() + // no local optimizations + if (element9 in objectArray.indices != range1.contains(element9)) throw AssertionError() + if (element9 !in objectArray.indices != !range1.contains(element9)) throw AssertionError() + if (!(element9 in objectArray.indices) != !range1.contains(element9)) throw AssertionError() + if (!(element9 !in objectArray.indices) != range1.contains(element9)) throw AssertionError() +} + +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() + // no local optimizations + if (element10 in objectArray.indices != range1.contains(element10)) throw AssertionError() + if (element10 !in objectArray.indices != !range1.contains(element10)) throw AssertionError() + if (!(element10 in objectArray.indices) != !range1.contains(element10)) throw AssertionError() + if (!(element10 !in objectArray.indices) != range1.contains(element10)) throw AssertionError() +} + +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() + // no local optimizations + if (element11 in objectArray.indices != range1.contains(element11)) throw AssertionError() + if (element11 !in objectArray.indices != !range1.contains(element11)) throw AssertionError() + if (!(element11 in objectArray.indices) != !range1.contains(element11)) throw AssertionError() + if (!(element11 !in objectArray.indices) != range1.contains(element11)) throw AssertionError() +} + +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() + // no local optimizations + if (element12 in objectArray.indices != range1.contains(element12)) throw AssertionError() + if (element12 !in objectArray.indices != !range1.contains(element12)) throw AssertionError() + if (!(element12 in objectArray.indices) != !range1.contains(element12)) throw AssertionError() + if (!(element12 !in objectArray.indices) != range1.contains(element12)) throw AssertionError() +} + +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() + // no local optimizations + if (element13 in objectArray.indices != range1.contains(element13)) throw AssertionError() + if (element13 !in objectArray.indices != !range1.contains(element13)) throw AssertionError() + if (!(element13 in objectArray.indices) != !range1.contains(element13)) throw AssertionError() + if (!(element13 !in objectArray.indices) != range1.contains(element13)) throw AssertionError() +} + +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() + // no local optimizations + if (element14 in objectArray.indices != range1.contains(element14)) throw AssertionError() + if (element14 !in objectArray.indices != !range1.contains(element14)) throw AssertionError() + if (!(element14 in objectArray.indices) != !range1.contains(element14)) throw AssertionError() + if (!(element14 !in objectArray.indices) != range1.contains(element14)) throw AssertionError() +} + +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() + // no local optimizations + if (element15 in objectArray.indices != range1.contains(element15)) throw AssertionError() + if (element15 !in objectArray.indices != !range1.contains(element15)) throw AssertionError() + if (!(element15 in objectArray.indices) != !range1.contains(element15)) throw AssertionError() + if (!(element15 !in objectArray.indices) != range1.contains(element15)) throw AssertionError() +} + +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() + // no local optimizations + if (element16 in objectArray.indices != range1.contains(element16)) throw AssertionError() + if (element16 !in objectArray.indices != !range1.contains(element16)) throw AssertionError() + if (!(element16 in objectArray.indices) != !range1.contains(element16)) throw AssertionError() + if (!(element16 !in objectArray.indices) != range1.contains(element16)) throw AssertionError() +} + +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() + // no local optimizations + if (element17 in objectArray.indices != range1.contains(element17)) throw AssertionError() + if (element17 !in objectArray.indices != !range1.contains(element17)) throw AssertionError() + if (!(element17 in objectArray.indices) != !range1.contains(element17)) throw AssertionError() + if (!(element17 !in objectArray.indices) != range1.contains(element17)) throw AssertionError() +} + +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() + // no local optimizations + if (element18 in objectArray.indices != range1.contains(element18)) throw AssertionError() + if (element18 !in objectArray.indices != !range1.contains(element18)) throw AssertionError() + if (!(element18 in objectArray.indices) != !range1.contains(element18)) throw AssertionError() + if (!(element18 !in objectArray.indices) != range1.contains(element18)) throw AssertionError() +} + +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() + // no local optimizations + if (element19 in objectArray.indices != range1.contains(element19)) throw AssertionError() + if (element19 !in objectArray.indices != !range1.contains(element19)) throw AssertionError() + if (!(element19 in objectArray.indices) != !range1.contains(element19)) throw AssertionError() + if (!(element19 !in objectArray.indices) != range1.contains(element19)) throw AssertionError() +} + +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() + // no local optimizations + if (element20 in objectArray.indices != range1.contains(element20)) throw AssertionError() + if (element20 !in objectArray.indices != !range1.contains(element20)) throw AssertionError() + if (!(element20 in objectArray.indices) != !range1.contains(element20)) throw AssertionError() + if (!(element20 !in objectArray.indices) != range1.contains(element20)) throw AssertionError() +} + +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() + // no local optimizations + if (element21 in objectArray.indices != range1.contains(element21)) throw AssertionError() + if (element21 !in objectArray.indices != !range1.contains(element21)) throw AssertionError() + if (!(element21 in objectArray.indices) != !range1.contains(element21)) throw AssertionError() + if (!(element21 !in objectArray.indices) != range1.contains(element21)) throw AssertionError() +} + +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() + // no local optimizations + if (element22 in objectArray.indices != range1.contains(element22)) throw AssertionError() + if (element22 !in objectArray.indices != !range1.contains(element22)) throw AssertionError() + if (!(element22 in objectArray.indices) != !range1.contains(element22)) throw AssertionError() + if (!(element22 !in objectArray.indices) != range1.contains(element22)) throw AssertionError() +} + +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() +} + +fun testR2xE0() { + // 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() + // no local optimizations + if (element0 in emptyIntArray.indices != range2.contains(element0)) throw AssertionError() + if (element0 !in emptyIntArray.indices != !range2.contains(element0)) throw AssertionError() + if (!(element0 in emptyIntArray.indices) != !range2.contains(element0)) throw AssertionError() + if (!(element0 !in emptyIntArray.indices) != range2.contains(element0)) throw AssertionError() +} + +fun testR2xE1() { + // 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() + // no local optimizations + if (element1 in emptyIntArray.indices != range2.contains(element1)) throw AssertionError() + if (element1 !in emptyIntArray.indices != !range2.contains(element1)) throw AssertionError() + if (!(element1 in emptyIntArray.indices) != !range2.contains(element1)) throw AssertionError() + if (!(element1 !in emptyIntArray.indices) != range2.contains(element1)) throw AssertionError() +} + +fun testR2xE2() { + // 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() + // no local optimizations + if (element2 in emptyIntArray.indices != range2.contains(element2)) throw AssertionError() + if (element2 !in emptyIntArray.indices != !range2.contains(element2)) throw AssertionError() + if (!(element2 in emptyIntArray.indices) != !range2.contains(element2)) throw AssertionError() + if (!(element2 !in emptyIntArray.indices) != range2.contains(element2)) throw AssertionError() +} + +fun testR2xE3() { + // 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() + // no local optimizations + if (element3 in emptyIntArray.indices != range2.contains(element3)) throw AssertionError() + if (element3 !in emptyIntArray.indices != !range2.contains(element3)) throw AssertionError() + if (!(element3 in emptyIntArray.indices) != !range2.contains(element3)) throw AssertionError() + if (!(element3 !in emptyIntArray.indices) != range2.contains(element3)) throw AssertionError() +} + +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() + // no local optimizations + if (element4 in emptyIntArray.indices != range2.contains(element4)) throw AssertionError() + if (element4 !in emptyIntArray.indices != !range2.contains(element4)) throw AssertionError() + if (!(element4 in emptyIntArray.indices) != !range2.contains(element4)) throw AssertionError() + if (!(element4 !in emptyIntArray.indices) != range2.contains(element4)) throw AssertionError() +} + +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() + // no local optimizations + if (element5 in emptyIntArray.indices != range2.contains(element5)) throw AssertionError() + if (element5 !in emptyIntArray.indices != !range2.contains(element5)) throw AssertionError() + if (!(element5 in emptyIntArray.indices) != !range2.contains(element5)) throw AssertionError() + if (!(element5 !in emptyIntArray.indices) != range2.contains(element5)) throw AssertionError() +} + +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() + // no local optimizations + if (element6 in emptyIntArray.indices != range2.contains(element6)) throw AssertionError() + if (element6 !in emptyIntArray.indices != !range2.contains(element6)) throw AssertionError() + if (!(element6 in emptyIntArray.indices) != !range2.contains(element6)) throw AssertionError() + if (!(element6 !in emptyIntArray.indices) != range2.contains(element6)) throw AssertionError() +} + +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() + // no local optimizations + if (element7 in emptyIntArray.indices != range2.contains(element7)) throw AssertionError() + if (element7 !in emptyIntArray.indices != !range2.contains(element7)) throw AssertionError() + if (!(element7 in emptyIntArray.indices) != !range2.contains(element7)) throw AssertionError() + if (!(element7 !in emptyIntArray.indices) != range2.contains(element7)) throw AssertionError() +} + +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() + // no local optimizations + if (element8 in emptyIntArray.indices != range2.contains(element8)) throw AssertionError() + if (element8 !in emptyIntArray.indices != !range2.contains(element8)) throw AssertionError() + if (!(element8 in emptyIntArray.indices) != !range2.contains(element8)) throw AssertionError() + if (!(element8 !in emptyIntArray.indices) != range2.contains(element8)) throw AssertionError() +} + +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() + // no local optimizations + if (element9 in emptyIntArray.indices != range2.contains(element9)) throw AssertionError() + if (element9 !in emptyIntArray.indices != !range2.contains(element9)) throw AssertionError() + if (!(element9 in emptyIntArray.indices) != !range2.contains(element9)) throw AssertionError() + if (!(element9 !in emptyIntArray.indices) != range2.contains(element9)) throw AssertionError() +} + +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() + // no local optimizations + if (element10 in emptyIntArray.indices != range2.contains(element10)) throw AssertionError() + if (element10 !in emptyIntArray.indices != !range2.contains(element10)) throw AssertionError() + if (!(element10 in emptyIntArray.indices) != !range2.contains(element10)) throw AssertionError() + if (!(element10 !in emptyIntArray.indices) != range2.contains(element10)) throw AssertionError() +} + +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() + // no local optimizations + if (element11 in emptyIntArray.indices != range2.contains(element11)) throw AssertionError() + if (element11 !in emptyIntArray.indices != !range2.contains(element11)) throw AssertionError() + if (!(element11 in emptyIntArray.indices) != !range2.contains(element11)) throw AssertionError() + if (!(element11 !in emptyIntArray.indices) != range2.contains(element11)) throw AssertionError() +} + +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() + // no local optimizations + if (element12 in emptyIntArray.indices != range2.contains(element12)) throw AssertionError() + if (element12 !in emptyIntArray.indices != !range2.contains(element12)) throw AssertionError() + if (!(element12 in emptyIntArray.indices) != !range2.contains(element12)) throw AssertionError() + if (!(element12 !in emptyIntArray.indices) != range2.contains(element12)) throw AssertionError() +} + +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() + // no local optimizations + if (element13 in emptyIntArray.indices != range2.contains(element13)) throw AssertionError() + if (element13 !in emptyIntArray.indices != !range2.contains(element13)) throw AssertionError() + if (!(element13 in emptyIntArray.indices) != !range2.contains(element13)) throw AssertionError() + if (!(element13 !in emptyIntArray.indices) != range2.contains(element13)) throw AssertionError() +} + +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() + // no local optimizations + if (element14 in emptyIntArray.indices != range2.contains(element14)) throw AssertionError() + if (element14 !in emptyIntArray.indices != !range2.contains(element14)) throw AssertionError() + if (!(element14 in emptyIntArray.indices) != !range2.contains(element14)) throw AssertionError() + if (!(element14 !in emptyIntArray.indices) != range2.contains(element14)) throw AssertionError() +} + +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() + // no local optimizations + if (element15 in emptyIntArray.indices != range2.contains(element15)) throw AssertionError() + if (element15 !in emptyIntArray.indices != !range2.contains(element15)) throw AssertionError() + if (!(element15 in emptyIntArray.indices) != !range2.contains(element15)) throw AssertionError() + if (!(element15 !in emptyIntArray.indices) != range2.contains(element15)) throw AssertionError() +} + +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() + // no local optimizations + if (element16 in emptyIntArray.indices != range2.contains(element16)) throw AssertionError() + if (element16 !in emptyIntArray.indices != !range2.contains(element16)) throw AssertionError() + if (!(element16 in emptyIntArray.indices) != !range2.contains(element16)) throw AssertionError() + if (!(element16 !in emptyIntArray.indices) != range2.contains(element16)) throw AssertionError() +} + +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() + // no local optimizations + if (element17 in emptyIntArray.indices != range2.contains(element17)) throw AssertionError() + if (element17 !in emptyIntArray.indices != !range2.contains(element17)) throw AssertionError() + if (!(element17 in emptyIntArray.indices) != !range2.contains(element17)) throw AssertionError() + if (!(element17 !in emptyIntArray.indices) != range2.contains(element17)) throw AssertionError() +} + +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() + // no local optimizations + if (element18 in emptyIntArray.indices != range2.contains(element18)) throw AssertionError() + if (element18 !in emptyIntArray.indices != !range2.contains(element18)) throw AssertionError() + if (!(element18 in emptyIntArray.indices) != !range2.contains(element18)) throw AssertionError() + if (!(element18 !in emptyIntArray.indices) != range2.contains(element18)) throw AssertionError() +} + +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() + // no local optimizations + if (element19 in emptyIntArray.indices != range2.contains(element19)) throw AssertionError() + if (element19 !in emptyIntArray.indices != !range2.contains(element19)) throw AssertionError() + if (!(element19 in emptyIntArray.indices) != !range2.contains(element19)) throw AssertionError() + if (!(element19 !in emptyIntArray.indices) != range2.contains(element19)) throw AssertionError() +} + +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() + // no local optimizations + if (element20 in emptyIntArray.indices != range2.contains(element20)) throw AssertionError() + if (element20 !in emptyIntArray.indices != !range2.contains(element20)) throw AssertionError() + if (!(element20 in emptyIntArray.indices) != !range2.contains(element20)) throw AssertionError() + if (!(element20 !in emptyIntArray.indices) != range2.contains(element20)) throw AssertionError() +} + +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() + // no local optimizations + if (element21 in emptyIntArray.indices != range2.contains(element21)) throw AssertionError() + if (element21 !in emptyIntArray.indices != !range2.contains(element21)) throw AssertionError() + if (!(element21 in emptyIntArray.indices) != !range2.contains(element21)) throw AssertionError() + if (!(element21 !in emptyIntArray.indices) != range2.contains(element21)) throw AssertionError() +} + +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() + // no local optimizations + if (element22 in emptyIntArray.indices != range2.contains(element22)) throw AssertionError() + if (element22 !in emptyIntArray.indices != !range2.contains(element22)) throw AssertionError() + if (!(element22 in emptyIntArray.indices) != !range2.contains(element22)) throw AssertionError() + if (!(element22 !in emptyIntArray.indices) != range2.contains(element22)) throw AssertionError() +} + +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() +} + +fun testR3xE0() { + // 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() + // no local optimizations + if (element0 in emptyObjectArray.indices != range3.contains(element0)) throw AssertionError() + if (element0 !in emptyObjectArray.indices != !range3.contains(element0)) throw AssertionError() + if (!(element0 in emptyObjectArray.indices) != !range3.contains(element0)) throw AssertionError() + if (!(element0 !in emptyObjectArray.indices) != range3.contains(element0)) throw AssertionError() +} + +fun testR3xE1() { + // 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() + // no local optimizations + if (element1 in emptyObjectArray.indices != range3.contains(element1)) throw AssertionError() + if (element1 !in emptyObjectArray.indices != !range3.contains(element1)) throw AssertionError() + if (!(element1 in emptyObjectArray.indices) != !range3.contains(element1)) throw AssertionError() + if (!(element1 !in emptyObjectArray.indices) != range3.contains(element1)) throw AssertionError() +} + +fun testR3xE2() { + // 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() + // no local optimizations + if (element2 in emptyObjectArray.indices != range3.contains(element2)) throw AssertionError() + if (element2 !in emptyObjectArray.indices != !range3.contains(element2)) throw AssertionError() + if (!(element2 in emptyObjectArray.indices) != !range3.contains(element2)) throw AssertionError() + if (!(element2 !in emptyObjectArray.indices) != range3.contains(element2)) throw AssertionError() +} + +fun testR3xE3() { + // 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() + // no local optimizations + if (element3 in emptyObjectArray.indices != range3.contains(element3)) throw AssertionError() + if (element3 !in emptyObjectArray.indices != !range3.contains(element3)) throw AssertionError() + if (!(element3 in emptyObjectArray.indices) != !range3.contains(element3)) throw AssertionError() + if (!(element3 !in emptyObjectArray.indices) != range3.contains(element3)) throw AssertionError() +} + +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() + // no local optimizations + if (element4 in emptyObjectArray.indices != range3.contains(element4)) throw AssertionError() + if (element4 !in emptyObjectArray.indices != !range3.contains(element4)) throw AssertionError() + if (!(element4 in emptyObjectArray.indices) != !range3.contains(element4)) throw AssertionError() + if (!(element4 !in emptyObjectArray.indices) != range3.contains(element4)) throw AssertionError() +} + +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() + // no local optimizations + if (element5 in emptyObjectArray.indices != range3.contains(element5)) throw AssertionError() + if (element5 !in emptyObjectArray.indices != !range3.contains(element5)) throw AssertionError() + if (!(element5 in emptyObjectArray.indices) != !range3.contains(element5)) throw AssertionError() + if (!(element5 !in emptyObjectArray.indices) != range3.contains(element5)) throw AssertionError() +} + +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() + // no local optimizations + if (element6 in emptyObjectArray.indices != range3.contains(element6)) throw AssertionError() + if (element6 !in emptyObjectArray.indices != !range3.contains(element6)) throw AssertionError() + if (!(element6 in emptyObjectArray.indices) != !range3.contains(element6)) throw AssertionError() + if (!(element6 !in emptyObjectArray.indices) != range3.contains(element6)) throw AssertionError() +} + +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() + // no local optimizations + if (element7 in emptyObjectArray.indices != range3.contains(element7)) throw AssertionError() + if (element7 !in emptyObjectArray.indices != !range3.contains(element7)) throw AssertionError() + if (!(element7 in emptyObjectArray.indices) != !range3.contains(element7)) throw AssertionError() + if (!(element7 !in emptyObjectArray.indices) != range3.contains(element7)) throw AssertionError() +} + +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() + // no local optimizations + if (element8 in emptyObjectArray.indices != range3.contains(element8)) throw AssertionError() + if (element8 !in emptyObjectArray.indices != !range3.contains(element8)) throw AssertionError() + if (!(element8 in emptyObjectArray.indices) != !range3.contains(element8)) throw AssertionError() + if (!(element8 !in emptyObjectArray.indices) != range3.contains(element8)) throw AssertionError() +} + +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() + // no local optimizations + if (element9 in emptyObjectArray.indices != range3.contains(element9)) throw AssertionError() + if (element9 !in emptyObjectArray.indices != !range3.contains(element9)) throw AssertionError() + if (!(element9 in emptyObjectArray.indices) != !range3.contains(element9)) throw AssertionError() + if (!(element9 !in emptyObjectArray.indices) != range3.contains(element9)) throw AssertionError() +} + +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() + // no local optimizations + if (element10 in emptyObjectArray.indices != range3.contains(element10)) throw AssertionError() + if (element10 !in emptyObjectArray.indices != !range3.contains(element10)) throw AssertionError() + if (!(element10 in emptyObjectArray.indices) != !range3.contains(element10)) throw AssertionError() + if (!(element10 !in emptyObjectArray.indices) != range3.contains(element10)) throw AssertionError() +} + +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() + // no local optimizations + if (element11 in emptyObjectArray.indices != range3.contains(element11)) throw AssertionError() + if (element11 !in emptyObjectArray.indices != !range3.contains(element11)) throw AssertionError() + if (!(element11 in emptyObjectArray.indices) != !range3.contains(element11)) throw AssertionError() + if (!(element11 !in emptyObjectArray.indices) != range3.contains(element11)) throw AssertionError() +} + +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() + // no local optimizations + if (element12 in emptyObjectArray.indices != range3.contains(element12)) throw AssertionError() + if (element12 !in emptyObjectArray.indices != !range3.contains(element12)) throw AssertionError() + if (!(element12 in emptyObjectArray.indices) != !range3.contains(element12)) throw AssertionError() + if (!(element12 !in emptyObjectArray.indices) != range3.contains(element12)) throw AssertionError() +} + +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() + // no local optimizations + if (element13 in emptyObjectArray.indices != range3.contains(element13)) throw AssertionError() + if (element13 !in emptyObjectArray.indices != !range3.contains(element13)) throw AssertionError() + if (!(element13 in emptyObjectArray.indices) != !range3.contains(element13)) throw AssertionError() + if (!(element13 !in emptyObjectArray.indices) != range3.contains(element13)) throw AssertionError() +} + +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() + // no local optimizations + if (element14 in emptyObjectArray.indices != range3.contains(element14)) throw AssertionError() + if (element14 !in emptyObjectArray.indices != !range3.contains(element14)) throw AssertionError() + if (!(element14 in emptyObjectArray.indices) != !range3.contains(element14)) throw AssertionError() + if (!(element14 !in emptyObjectArray.indices) != range3.contains(element14)) throw AssertionError() +} + +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() + // no local optimizations + if (element15 in emptyObjectArray.indices != range3.contains(element15)) throw AssertionError() + if (element15 !in emptyObjectArray.indices != !range3.contains(element15)) throw AssertionError() + if (!(element15 in emptyObjectArray.indices) != !range3.contains(element15)) throw AssertionError() + if (!(element15 !in emptyObjectArray.indices) != range3.contains(element15)) throw AssertionError() +} + +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() + // no local optimizations + if (element16 in emptyObjectArray.indices != range3.contains(element16)) throw AssertionError() + if (element16 !in emptyObjectArray.indices != !range3.contains(element16)) throw AssertionError() + if (!(element16 in emptyObjectArray.indices) != !range3.contains(element16)) throw AssertionError() + if (!(element16 !in emptyObjectArray.indices) != range3.contains(element16)) throw AssertionError() +} + +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() + // no local optimizations + if (element17 in emptyObjectArray.indices != range3.contains(element17)) throw AssertionError() + if (element17 !in emptyObjectArray.indices != !range3.contains(element17)) throw AssertionError() + if (!(element17 in emptyObjectArray.indices) != !range3.contains(element17)) throw AssertionError() + if (!(element17 !in emptyObjectArray.indices) != range3.contains(element17)) throw AssertionError() +} + +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() + // no local optimizations + if (element18 in emptyObjectArray.indices != range3.contains(element18)) throw AssertionError() + if (element18 !in emptyObjectArray.indices != !range3.contains(element18)) throw AssertionError() + if (!(element18 in emptyObjectArray.indices) != !range3.contains(element18)) throw AssertionError() + if (!(element18 !in emptyObjectArray.indices) != range3.contains(element18)) throw AssertionError() +} + +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() + // no local optimizations + if (element19 in emptyObjectArray.indices != range3.contains(element19)) throw AssertionError() + if (element19 !in emptyObjectArray.indices != !range3.contains(element19)) throw AssertionError() + if (!(element19 in emptyObjectArray.indices) != !range3.contains(element19)) throw AssertionError() + if (!(element19 !in emptyObjectArray.indices) != range3.contains(element19)) throw AssertionError() +} + +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() + // no local optimizations + if (element20 in emptyObjectArray.indices != range3.contains(element20)) throw AssertionError() + if (element20 !in emptyObjectArray.indices != !range3.contains(element20)) throw AssertionError() + if (!(element20 in emptyObjectArray.indices) != !range3.contains(element20)) throw AssertionError() + if (!(element20 !in emptyObjectArray.indices) != range3.contains(element20)) throw AssertionError() +} + +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() + // no local optimizations + if (element21 in emptyObjectArray.indices != range3.contains(element21)) throw AssertionError() + if (element21 !in emptyObjectArray.indices != !range3.contains(element21)) throw AssertionError() + if (!(element21 in emptyObjectArray.indices) != !range3.contains(element21)) throw AssertionError() + if (!(element21 !in emptyObjectArray.indices) != range3.contains(element21)) throw AssertionError() +} + +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() + // no local optimizations + if (element22 in emptyObjectArray.indices != range3.contains(element22)) throw AssertionError() + if (element22 !in emptyObjectArray.indices != !range3.contains(element22)) throw AssertionError() + if (!(element22 in emptyObjectArray.indices) != !range3.contains(element22)) throw AssertionError() + if (!(element22 !in emptyObjectArray.indices) != range3.contains(element22)) throw AssertionError() +} + +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() + // no local optimizations + if (element23 in emptyObjectArray.indices != range3.contains(element23)) throw AssertionError() + if (element23 !in emptyObjectArray.indices != !range3.contains(element23)) throw AssertionError() + if (!(element23 in emptyObjectArray.indices) != !range3.contains(element23)) throw AssertionError() + 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/charDownTo.kt b/compiler/testData/codegen/box/ranges/contains/generated/charDownTo.kt new file mode 100644 index 00000000000..a2256df17ba --- /dev/null +++ b/compiler/testData/codegen/box/ranges/contains/generated/charDownTo.kt @@ -0,0 +1,159 @@ +// Auto-generated by GenerateInRangeExpressionTestData. Do not edit! +// WITH_RUNTIME + + + +val range0 = '3' downTo '1' +val range1 = '1' downTo '3' + +val element0 = '0' +val element1 = '1' +val element2 = '2' +val element3 = '3' +val element4 = '4' + +fun box(): String { + testR0xE0() + testR0xE1() + testR0xE2() + testR0xE3() + testR0xE4() + testR1xE0() + testR1xE1() + testR1xE2() + testR1xE3() + testR1xE4() + return "OK" +} + +fun testR0xE0() { + // with possible local optimizations + if ('0' in '3' downTo '1' != range0.contains('0')) throw AssertionError() + if ('0' !in '3' downTo '1' != !range0.contains('0')) throw AssertionError() + if (!('0' in '3' downTo '1') != !range0.contains('0')) throw AssertionError() + if (!('0' !in '3' downTo '1') != range0.contains('0')) throw AssertionError() + // no local optimizations + if (element0 in '3' downTo '1' != range0.contains(element0)) throw AssertionError() + if (element0 !in '3' downTo '1' != !range0.contains(element0)) throw AssertionError() + if (!(element0 in '3' downTo '1') != !range0.contains(element0)) throw AssertionError() + if (!(element0 !in '3' downTo '1') != range0.contains(element0)) throw AssertionError() +} + +fun testR0xE1() { + // with possible local optimizations + if ('1' in '3' downTo '1' != range0.contains('1')) throw AssertionError() + if ('1' !in '3' downTo '1' != !range0.contains('1')) throw AssertionError() + if (!('1' in '3' downTo '1') != !range0.contains('1')) throw AssertionError() + if (!('1' !in '3' downTo '1') != range0.contains('1')) throw AssertionError() + // no local optimizations + if (element1 in '3' downTo '1' != range0.contains(element1)) throw AssertionError() + if (element1 !in '3' downTo '1' != !range0.contains(element1)) throw AssertionError() + if (!(element1 in '3' downTo '1') != !range0.contains(element1)) throw AssertionError() + if (!(element1 !in '3' downTo '1') != range0.contains(element1)) throw AssertionError() +} + +fun testR0xE2() { + // with possible local optimizations + if ('2' in '3' downTo '1' != range0.contains('2')) throw AssertionError() + if ('2' !in '3' downTo '1' != !range0.contains('2')) throw AssertionError() + if (!('2' in '3' downTo '1') != !range0.contains('2')) throw AssertionError() + if (!('2' !in '3' downTo '1') != range0.contains('2')) throw AssertionError() + // no local optimizations + if (element2 in '3' downTo '1' != range0.contains(element2)) throw AssertionError() + if (element2 !in '3' downTo '1' != !range0.contains(element2)) throw AssertionError() + if (!(element2 in '3' downTo '1') != !range0.contains(element2)) throw AssertionError() + if (!(element2 !in '3' downTo '1') != range0.contains(element2)) throw AssertionError() +} + +fun testR0xE3() { + // with possible local optimizations + if ('3' in '3' downTo '1' != range0.contains('3')) throw AssertionError() + if ('3' !in '3' downTo '1' != !range0.contains('3')) throw AssertionError() + if (!('3' in '3' downTo '1') != !range0.contains('3')) throw AssertionError() + if (!('3' !in '3' downTo '1') != range0.contains('3')) throw AssertionError() + // no local optimizations + if (element3 in '3' downTo '1' != range0.contains(element3)) throw AssertionError() + if (element3 !in '3' downTo '1' != !range0.contains(element3)) throw AssertionError() + if (!(element3 in '3' downTo '1') != !range0.contains(element3)) throw AssertionError() + if (!(element3 !in '3' downTo '1') != range0.contains(element3)) throw AssertionError() +} + +fun testR0xE4() { + // with possible local optimizations + if ('4' in '3' downTo '1' != range0.contains('4')) throw AssertionError() + if ('4' !in '3' downTo '1' != !range0.contains('4')) throw AssertionError() + if (!('4' in '3' downTo '1') != !range0.contains('4')) throw AssertionError() + if (!('4' !in '3' downTo '1') != range0.contains('4')) throw AssertionError() + // no local optimizations + if (element4 in '3' downTo '1' != range0.contains(element4)) throw AssertionError() + if (element4 !in '3' downTo '1' != !range0.contains(element4)) throw AssertionError() + if (!(element4 in '3' downTo '1') != !range0.contains(element4)) throw AssertionError() + if (!(element4 !in '3' downTo '1') != range0.contains(element4)) throw AssertionError() +} + +fun testR1xE0() { + // with possible local optimizations + if ('0' in '1' downTo '3' != range1.contains('0')) throw AssertionError() + if ('0' !in '1' downTo '3' != !range1.contains('0')) throw AssertionError() + if (!('0' in '1' downTo '3') != !range1.contains('0')) throw AssertionError() + if (!('0' !in '1' downTo '3') != range1.contains('0')) throw AssertionError() + // no local optimizations + if (element0 in '1' downTo '3' != range1.contains(element0)) throw AssertionError() + if (element0 !in '1' downTo '3' != !range1.contains(element0)) throw AssertionError() + if (!(element0 in '1' downTo '3') != !range1.contains(element0)) throw AssertionError() + if (!(element0 !in '1' downTo '3') != range1.contains(element0)) throw AssertionError() +} + +fun testR1xE1() { + // with possible local optimizations + if ('1' in '1' downTo '3' != range1.contains('1')) throw AssertionError() + if ('1' !in '1' downTo '3' != !range1.contains('1')) throw AssertionError() + if (!('1' in '1' downTo '3') != !range1.contains('1')) throw AssertionError() + if (!('1' !in '1' downTo '3') != range1.contains('1')) throw AssertionError() + // no local optimizations + if (element1 in '1' downTo '3' != range1.contains(element1)) throw AssertionError() + if (element1 !in '1' downTo '3' != !range1.contains(element1)) throw AssertionError() + if (!(element1 in '1' downTo '3') != !range1.contains(element1)) throw AssertionError() + if (!(element1 !in '1' downTo '3') != range1.contains(element1)) throw AssertionError() +} + +fun testR1xE2() { + // with possible local optimizations + if ('2' in '1' downTo '3' != range1.contains('2')) throw AssertionError() + if ('2' !in '1' downTo '3' != !range1.contains('2')) throw AssertionError() + if (!('2' in '1' downTo '3') != !range1.contains('2')) throw AssertionError() + if (!('2' !in '1' downTo '3') != range1.contains('2')) throw AssertionError() + // no local optimizations + if (element2 in '1' downTo '3' != range1.contains(element2)) throw AssertionError() + if (element2 !in '1' downTo '3' != !range1.contains(element2)) throw AssertionError() + if (!(element2 in '1' downTo '3') != !range1.contains(element2)) throw AssertionError() + if (!(element2 !in '1' downTo '3') != range1.contains(element2)) throw AssertionError() +} + +fun testR1xE3() { + // with possible local optimizations + if ('3' in '1' downTo '3' != range1.contains('3')) throw AssertionError() + if ('3' !in '1' downTo '3' != !range1.contains('3')) throw AssertionError() + if (!('3' in '1' downTo '3') != !range1.contains('3')) throw AssertionError() + if (!('3' !in '1' downTo '3') != range1.contains('3')) throw AssertionError() + // no local optimizations + if (element3 in '1' downTo '3' != range1.contains(element3)) throw AssertionError() + if (element3 !in '1' downTo '3' != !range1.contains(element3)) throw AssertionError() + if (!(element3 in '1' downTo '3') != !range1.contains(element3)) throw AssertionError() + if (!(element3 !in '1' downTo '3') != range1.contains(element3)) throw AssertionError() +} + +fun testR1xE4() { + // with possible local optimizations + if ('4' in '1' downTo '3' != range1.contains('4')) throw AssertionError() + if ('4' !in '1' downTo '3' != !range1.contains('4')) throw AssertionError() + if (!('4' in '1' downTo '3') != !range1.contains('4')) throw AssertionError() + if (!('4' !in '1' downTo '3') != range1.contains('4')) throw AssertionError() + // no local optimizations + if (element4 in '1' downTo '3' != range1.contains(element4)) throw AssertionError() + if (element4 !in '1' downTo '3' != !range1.contains(element4)) throw AssertionError() + if (!(element4 in '1' downTo '3') != !range1.contains(element4)) throw AssertionError() + if (!(element4 !in '1' downTo '3') != range1.contains(element4)) throw AssertionError() +} + + diff --git a/compiler/testData/codegen/box/ranges/contains/generated/charRangeLiteral.kt b/compiler/testData/codegen/box/ranges/contains/generated/charRangeLiteral.kt new file mode 100644 index 00000000000..ba93f6b044d --- /dev/null +++ b/compiler/testData/codegen/box/ranges/contains/generated/charRangeLiteral.kt @@ -0,0 +1,159 @@ +// Auto-generated by GenerateInRangeExpressionTestData. Do not edit! +// WITH_RUNTIME + + + +val range0 = '1' .. '3' +val range1 = '3' .. '1' + +val element0 = '0' +val element1 = '1' +val element2 = '2' +val element3 = '3' +val element4 = '4' + +fun box(): String { + testR0xE0() + testR0xE1() + testR0xE2() + testR0xE3() + testR0xE4() + testR1xE0() + testR1xE1() + testR1xE2() + testR1xE3() + testR1xE4() + return "OK" +} + +fun testR0xE0() { + // 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() + // no local optimizations + if (element0 in '1' .. '3' != range0.contains(element0)) throw AssertionError() + if (element0 !in '1' .. '3' != !range0.contains(element0)) throw AssertionError() + if (!(element0 in '1' .. '3') != !range0.contains(element0)) throw AssertionError() + if (!(element0 !in '1' .. '3') != range0.contains(element0)) throw AssertionError() +} + +fun testR0xE1() { + // 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() + // no local optimizations + if (element1 in '1' .. '3' != range0.contains(element1)) throw AssertionError() + if (element1 !in '1' .. '3' != !range0.contains(element1)) throw AssertionError() + if (!(element1 in '1' .. '3') != !range0.contains(element1)) throw AssertionError() + if (!(element1 !in '1' .. '3') != range0.contains(element1)) throw AssertionError() +} + +fun testR0xE2() { + // 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() + // no local optimizations + if (element2 in '1' .. '3' != range0.contains(element2)) throw AssertionError() + if (element2 !in '1' .. '3' != !range0.contains(element2)) throw AssertionError() + if (!(element2 in '1' .. '3') != !range0.contains(element2)) throw AssertionError() + if (!(element2 !in '1' .. '3') != range0.contains(element2)) throw AssertionError() +} + +fun testR0xE3() { + // 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 (element3 in '1' .. '3' != range0.contains(element3)) throw AssertionError() + if (element3 !in '1' .. '3' != !range0.contains(element3)) throw AssertionError() + if (!(element3 in '1' .. '3') != !range0.contains(element3)) throw AssertionError() + if (!(element3 !in '1' .. '3') != range0.contains(element3)) throw AssertionError() +} + +fun testR0xE4() { + // 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 (element4 in '1' .. '3' != range0.contains(element4)) throw AssertionError() + if (element4 !in '1' .. '3' != !range0.contains(element4)) throw AssertionError() + if (!(element4 in '1' .. '3') != !range0.contains(element4)) throw AssertionError() + if (!(element4 !in '1' .. '3') != range0.contains(element4)) throw AssertionError() +} + +fun testR1xE0() { + // 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() + // no local optimizations + if (element0 in '3' .. '1' != range1.contains(element0)) throw AssertionError() + if (element0 !in '3' .. '1' != !range1.contains(element0)) throw AssertionError() + if (!(element0 in '3' .. '1') != !range1.contains(element0)) throw AssertionError() + if (!(element0 !in '3' .. '1') != range1.contains(element0)) throw AssertionError() +} + +fun testR1xE1() { + // 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() + // no local optimizations + if (element1 in '3' .. '1' != range1.contains(element1)) throw AssertionError() + if (element1 !in '3' .. '1' != !range1.contains(element1)) throw AssertionError() + if (!(element1 in '3' .. '1') != !range1.contains(element1)) throw AssertionError() + if (!(element1 !in '3' .. '1') != range1.contains(element1)) throw AssertionError() +} + +fun testR1xE2() { + // 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() + // no local optimizations + if (element2 in '3' .. '1' != range1.contains(element2)) throw AssertionError() + if (element2 !in '3' .. '1' != !range1.contains(element2)) throw AssertionError() + if (!(element2 in '3' .. '1') != !range1.contains(element2)) throw AssertionError() + if (!(element2 !in '3' .. '1') != range1.contains(element2)) throw AssertionError() +} + +fun testR1xE3() { + // 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 (element3 in '3' .. '1' != range1.contains(element3)) throw AssertionError() + if (element3 !in '3' .. '1' != !range1.contains(element3)) throw AssertionError() + if (!(element3 in '3' .. '1') != !range1.contains(element3)) throw AssertionError() + if (!(element3 !in '3' .. '1') != range1.contains(element3)) throw AssertionError() +} + +fun testR1xE4() { + // 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 (element4 in '3' .. '1' != range1.contains(element4)) throw AssertionError() + if (element4 !in '3' .. '1' != !range1.contains(element4)) throw AssertionError() + if (!(element4 in '3' .. '1') != !range1.contains(element4)) throw AssertionError() + if (!(element4 !in '3' .. '1') != range1.contains(element4)) throw AssertionError() +} + + diff --git a/compiler/testData/codegen/box/ranges/contains/generated/charSequenceIndices.kt b/compiler/testData/codegen/box/ranges/contains/generated/charSequenceIndices.kt new file mode 100644 index 00000000000..7f6d4ac8921 --- /dev/null +++ b/compiler/testData/codegen/box/ranges/contains/generated/charSequenceIndices.kt @@ -0,0 +1,1059 @@ +// Auto-generated by GenerateInRangeExpressionTestData. Do not edit! +// WITH_RUNTIME + +val charSequence: CharSequence = "123" +val emptyCharSequence: CharSequence = "" + +val range0 = charSequence.indices +val range1 = emptyCharSequence.indices + +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() + +fun box(): String { + testR0xE0() + testR0xE1() + testR0xE2() + testR0xE3() + testR0xE4() + testR0xE5() + testR0xE6() + testR0xE7() + testR0xE8() + 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() + testR1xE3() + testR1xE4() + testR1xE5() + testR1xE6() + testR1xE7() + testR1xE8() + 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 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 (element0 in charSequence.indices != range0.contains(element0)) throw AssertionError() + if (element0 !in charSequence.indices != !range0.contains(element0)) throw AssertionError() + if (!(element0 in charSequence.indices) != !range0.contains(element0)) throw AssertionError() + if (!(element0 !in charSequence.indices) != range0.contains(element0)) throw AssertionError() +} + +fun testR0xE1() { + // 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() + // no local optimizations + if (element1 in charSequence.indices != range0.contains(element1)) throw AssertionError() + if (element1 !in charSequence.indices != !range0.contains(element1)) throw AssertionError() + if (!(element1 in charSequence.indices) != !range0.contains(element1)) throw AssertionError() + if (!(element1 !in charSequence.indices) != range0.contains(element1)) throw AssertionError() +} + +fun testR0xE2() { + // 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() + // no local optimizations + if (element2 in charSequence.indices != range0.contains(element2)) throw AssertionError() + if (element2 !in charSequence.indices != !range0.contains(element2)) throw AssertionError() + if (!(element2 in charSequence.indices) != !range0.contains(element2)) throw AssertionError() + if (!(element2 !in charSequence.indices) != range0.contains(element2)) throw AssertionError() +} + +fun testR0xE3() { + // 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() + // no local optimizations + if (element3 in charSequence.indices != range0.contains(element3)) throw AssertionError() + if (element3 !in charSequence.indices != !range0.contains(element3)) throw AssertionError() + if (!(element3 in charSequence.indices) != !range0.contains(element3)) throw AssertionError() + if (!(element3 !in charSequence.indices) != range0.contains(element3)) throw AssertionError() +} + +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() + // no local optimizations + if (element4 in charSequence.indices != range0.contains(element4)) throw AssertionError() + if (element4 !in charSequence.indices != !range0.contains(element4)) throw AssertionError() + if (!(element4 in charSequence.indices) != !range0.contains(element4)) throw AssertionError() + if (!(element4 !in charSequence.indices) != range0.contains(element4)) throw AssertionError() +} + +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() + // no local optimizations + if (element5 in charSequence.indices != range0.contains(element5)) throw AssertionError() + if (element5 !in charSequence.indices != !range0.contains(element5)) throw AssertionError() + if (!(element5 in charSequence.indices) != !range0.contains(element5)) throw AssertionError() + if (!(element5 !in charSequence.indices) != range0.contains(element5)) throw AssertionError() +} + +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() + // no local optimizations + if (element6 in charSequence.indices != range0.contains(element6)) throw AssertionError() + if (element6 !in charSequence.indices != !range0.contains(element6)) throw AssertionError() + if (!(element6 in charSequence.indices) != !range0.contains(element6)) throw AssertionError() + if (!(element6 !in charSequence.indices) != range0.contains(element6)) throw AssertionError() +} + +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() + // no local optimizations + if (element7 in charSequence.indices != range0.contains(element7)) throw AssertionError() + if (element7 !in charSequence.indices != !range0.contains(element7)) throw AssertionError() + if (!(element7 in charSequence.indices) != !range0.contains(element7)) throw AssertionError() + if (!(element7 !in charSequence.indices) != range0.contains(element7)) throw AssertionError() +} + +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() + // no local optimizations + if (element8 in charSequence.indices != range0.contains(element8)) throw AssertionError() + if (element8 !in charSequence.indices != !range0.contains(element8)) throw AssertionError() + if (!(element8 in charSequence.indices) != !range0.contains(element8)) throw AssertionError() + if (!(element8 !in charSequence.indices) != range0.contains(element8)) throw AssertionError() +} + +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() + // no local optimizations + if (element9 in charSequence.indices != range0.contains(element9)) throw AssertionError() + if (element9 !in charSequence.indices != !range0.contains(element9)) throw AssertionError() + if (!(element9 in charSequence.indices) != !range0.contains(element9)) throw AssertionError() + if (!(element9 !in charSequence.indices) != range0.contains(element9)) throw AssertionError() +} + +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() + // no local optimizations + if (element10 in charSequence.indices != range0.contains(element10)) throw AssertionError() + if (element10 !in charSequence.indices != !range0.contains(element10)) throw AssertionError() + if (!(element10 in charSequence.indices) != !range0.contains(element10)) throw AssertionError() + if (!(element10 !in charSequence.indices) != range0.contains(element10)) throw AssertionError() +} + +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() + // no local optimizations + if (element11 in charSequence.indices != range0.contains(element11)) throw AssertionError() + if (element11 !in charSequence.indices != !range0.contains(element11)) throw AssertionError() + if (!(element11 in charSequence.indices) != !range0.contains(element11)) throw AssertionError() + if (!(element11 !in charSequence.indices) != range0.contains(element11)) throw AssertionError() +} + +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() + // no local optimizations + if (element12 in charSequence.indices != range0.contains(element12)) throw AssertionError() + if (element12 !in charSequence.indices != !range0.contains(element12)) throw AssertionError() + if (!(element12 in charSequence.indices) != !range0.contains(element12)) throw AssertionError() + if (!(element12 !in charSequence.indices) != range0.contains(element12)) throw AssertionError() +} + +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() + // no local optimizations + if (element13 in charSequence.indices != range0.contains(element13)) throw AssertionError() + if (element13 !in charSequence.indices != !range0.contains(element13)) throw AssertionError() + if (!(element13 in charSequence.indices) != !range0.contains(element13)) throw AssertionError() + if (!(element13 !in charSequence.indices) != range0.contains(element13)) throw AssertionError() +} + +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() + // no local optimizations + if (element14 in charSequence.indices != range0.contains(element14)) throw AssertionError() + if (element14 !in charSequence.indices != !range0.contains(element14)) throw AssertionError() + if (!(element14 in charSequence.indices) != !range0.contains(element14)) throw AssertionError() + if (!(element14 !in charSequence.indices) != range0.contains(element14)) throw AssertionError() +} + +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() + // no local optimizations + if (element15 in charSequence.indices != range0.contains(element15)) throw AssertionError() + if (element15 !in charSequence.indices != !range0.contains(element15)) throw AssertionError() + if (!(element15 in charSequence.indices) != !range0.contains(element15)) throw AssertionError() + if (!(element15 !in charSequence.indices) != range0.contains(element15)) throw AssertionError() +} + +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() + // no local optimizations + if (element16 in charSequence.indices != range0.contains(element16)) throw AssertionError() + if (element16 !in charSequence.indices != !range0.contains(element16)) throw AssertionError() + if (!(element16 in charSequence.indices) != !range0.contains(element16)) throw AssertionError() + if (!(element16 !in charSequence.indices) != range0.contains(element16)) throw AssertionError() +} + +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() + // no local optimizations + if (element17 in charSequence.indices != range0.contains(element17)) throw AssertionError() + if (element17 !in charSequence.indices != !range0.contains(element17)) throw AssertionError() + if (!(element17 in charSequence.indices) != !range0.contains(element17)) throw AssertionError() + if (!(element17 !in charSequence.indices) != range0.contains(element17)) throw AssertionError() +} + +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() + // no local optimizations + if (element18 in charSequence.indices != range0.contains(element18)) throw AssertionError() + if (element18 !in charSequence.indices != !range0.contains(element18)) throw AssertionError() + if (!(element18 in charSequence.indices) != !range0.contains(element18)) throw AssertionError() + if (!(element18 !in charSequence.indices) != range0.contains(element18)) throw AssertionError() +} + +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() + // no local optimizations + if (element19 in charSequence.indices != range0.contains(element19)) throw AssertionError() + if (element19 !in charSequence.indices != !range0.contains(element19)) throw AssertionError() + if (!(element19 in charSequence.indices) != !range0.contains(element19)) throw AssertionError() + if (!(element19 !in charSequence.indices) != range0.contains(element19)) throw AssertionError() +} + +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() + // no local optimizations + if (element20 in charSequence.indices != range0.contains(element20)) throw AssertionError() + if (element20 !in charSequence.indices != !range0.contains(element20)) throw AssertionError() + if (!(element20 in charSequence.indices) != !range0.contains(element20)) throw AssertionError() + if (!(element20 !in charSequence.indices) != range0.contains(element20)) throw AssertionError() +} + +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() + // no local optimizations + if (element21 in charSequence.indices != range0.contains(element21)) throw AssertionError() + if (element21 !in charSequence.indices != !range0.contains(element21)) throw AssertionError() + if (!(element21 in charSequence.indices) != !range0.contains(element21)) throw AssertionError() + if (!(element21 !in charSequence.indices) != range0.contains(element21)) throw AssertionError() +} + +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() + // no local optimizations + if (element22 in charSequence.indices != range0.contains(element22)) throw AssertionError() + if (element22 !in charSequence.indices != !range0.contains(element22)) throw AssertionError() + if (!(element22 in charSequence.indices) != !range0.contains(element22)) throw AssertionError() + if (!(element22 !in charSequence.indices) != range0.contains(element22)) throw AssertionError() +} + +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() +} + +fun testR1xE0() { + // 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() + // no local optimizations + if (element0 in emptyCharSequence.indices != range1.contains(element0)) throw AssertionError() + if (element0 !in emptyCharSequence.indices != !range1.contains(element0)) throw AssertionError() + if (!(element0 in emptyCharSequence.indices) != !range1.contains(element0)) throw AssertionError() + if (!(element0 !in emptyCharSequence.indices) != range1.contains(element0)) throw AssertionError() +} + +fun testR1xE1() { + // 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() + // no local optimizations + if (element1 in emptyCharSequence.indices != range1.contains(element1)) throw AssertionError() + if (element1 !in emptyCharSequence.indices != !range1.contains(element1)) throw AssertionError() + if (!(element1 in emptyCharSequence.indices) != !range1.contains(element1)) throw AssertionError() + if (!(element1 !in emptyCharSequence.indices) != range1.contains(element1)) throw AssertionError() +} + +fun testR1xE2() { + // 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() + // no local optimizations + if (element2 in emptyCharSequence.indices != range1.contains(element2)) throw AssertionError() + if (element2 !in emptyCharSequence.indices != !range1.contains(element2)) throw AssertionError() + if (!(element2 in emptyCharSequence.indices) != !range1.contains(element2)) throw AssertionError() + if (!(element2 !in emptyCharSequence.indices) != range1.contains(element2)) throw AssertionError() +} + +fun testR1xE3() { + // 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() + // no local optimizations + if (element3 in emptyCharSequence.indices != range1.contains(element3)) throw AssertionError() + if (element3 !in emptyCharSequence.indices != !range1.contains(element3)) throw AssertionError() + if (!(element3 in emptyCharSequence.indices) != !range1.contains(element3)) throw AssertionError() + if (!(element3 !in emptyCharSequence.indices) != range1.contains(element3)) throw AssertionError() +} + +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() + // no local optimizations + if (element4 in emptyCharSequence.indices != range1.contains(element4)) throw AssertionError() + if (element4 !in emptyCharSequence.indices != !range1.contains(element4)) throw AssertionError() + if (!(element4 in emptyCharSequence.indices) != !range1.contains(element4)) throw AssertionError() + if (!(element4 !in emptyCharSequence.indices) != range1.contains(element4)) throw AssertionError() +} + +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() + // no local optimizations + if (element5 in emptyCharSequence.indices != range1.contains(element5)) throw AssertionError() + if (element5 !in emptyCharSequence.indices != !range1.contains(element5)) throw AssertionError() + if (!(element5 in emptyCharSequence.indices) != !range1.contains(element5)) throw AssertionError() + if (!(element5 !in emptyCharSequence.indices) != range1.contains(element5)) throw AssertionError() +} + +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() + // no local optimizations + if (element6 in emptyCharSequence.indices != range1.contains(element6)) throw AssertionError() + if (element6 !in emptyCharSequence.indices != !range1.contains(element6)) throw AssertionError() + if (!(element6 in emptyCharSequence.indices) != !range1.contains(element6)) throw AssertionError() + if (!(element6 !in emptyCharSequence.indices) != range1.contains(element6)) throw AssertionError() +} + +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() + // no local optimizations + if (element7 in emptyCharSequence.indices != range1.contains(element7)) throw AssertionError() + if (element7 !in emptyCharSequence.indices != !range1.contains(element7)) throw AssertionError() + if (!(element7 in emptyCharSequence.indices) != !range1.contains(element7)) throw AssertionError() + if (!(element7 !in emptyCharSequence.indices) != range1.contains(element7)) throw AssertionError() +} + +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() + // no local optimizations + if (element8 in emptyCharSequence.indices != range1.contains(element8)) throw AssertionError() + if (element8 !in emptyCharSequence.indices != !range1.contains(element8)) throw AssertionError() + if (!(element8 in emptyCharSequence.indices) != !range1.contains(element8)) throw AssertionError() + if (!(element8 !in emptyCharSequence.indices) != range1.contains(element8)) throw AssertionError() +} + +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() + // no local optimizations + if (element9 in emptyCharSequence.indices != range1.contains(element9)) throw AssertionError() + if (element9 !in emptyCharSequence.indices != !range1.contains(element9)) throw AssertionError() + if (!(element9 in emptyCharSequence.indices) != !range1.contains(element9)) throw AssertionError() + if (!(element9 !in emptyCharSequence.indices) != range1.contains(element9)) throw AssertionError() +} + +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() + // no local optimizations + if (element10 in emptyCharSequence.indices != range1.contains(element10)) throw AssertionError() + if (element10 !in emptyCharSequence.indices != !range1.contains(element10)) throw AssertionError() + if (!(element10 in emptyCharSequence.indices) != !range1.contains(element10)) throw AssertionError() + if (!(element10 !in emptyCharSequence.indices) != range1.contains(element10)) throw AssertionError() +} + +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() + // no local optimizations + if (element11 in emptyCharSequence.indices != range1.contains(element11)) throw AssertionError() + if (element11 !in emptyCharSequence.indices != !range1.contains(element11)) throw AssertionError() + if (!(element11 in emptyCharSequence.indices) != !range1.contains(element11)) throw AssertionError() + if (!(element11 !in emptyCharSequence.indices) != range1.contains(element11)) throw AssertionError() +} + +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() + // no local optimizations + if (element12 in emptyCharSequence.indices != range1.contains(element12)) throw AssertionError() + if (element12 !in emptyCharSequence.indices != !range1.contains(element12)) throw AssertionError() + if (!(element12 in emptyCharSequence.indices) != !range1.contains(element12)) throw AssertionError() + if (!(element12 !in emptyCharSequence.indices) != range1.contains(element12)) throw AssertionError() +} + +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() + // no local optimizations + if (element13 in emptyCharSequence.indices != range1.contains(element13)) throw AssertionError() + if (element13 !in emptyCharSequence.indices != !range1.contains(element13)) throw AssertionError() + if (!(element13 in emptyCharSequence.indices) != !range1.contains(element13)) throw AssertionError() + if (!(element13 !in emptyCharSequence.indices) != range1.contains(element13)) throw AssertionError() +} + +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() + // no local optimizations + if (element14 in emptyCharSequence.indices != range1.contains(element14)) throw AssertionError() + if (element14 !in emptyCharSequence.indices != !range1.contains(element14)) throw AssertionError() + if (!(element14 in emptyCharSequence.indices) != !range1.contains(element14)) throw AssertionError() + if (!(element14 !in emptyCharSequence.indices) != range1.contains(element14)) throw AssertionError() +} + +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() + // no local optimizations + if (element15 in emptyCharSequence.indices != range1.contains(element15)) throw AssertionError() + if (element15 !in emptyCharSequence.indices != !range1.contains(element15)) throw AssertionError() + if (!(element15 in emptyCharSequence.indices) != !range1.contains(element15)) throw AssertionError() + if (!(element15 !in emptyCharSequence.indices) != range1.contains(element15)) throw AssertionError() +} + +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() + // no local optimizations + if (element16 in emptyCharSequence.indices != range1.contains(element16)) throw AssertionError() + if (element16 !in emptyCharSequence.indices != !range1.contains(element16)) throw AssertionError() + if (!(element16 in emptyCharSequence.indices) != !range1.contains(element16)) throw AssertionError() + if (!(element16 !in emptyCharSequence.indices) != range1.contains(element16)) throw AssertionError() +} + +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() + // no local optimizations + if (element17 in emptyCharSequence.indices != range1.contains(element17)) throw AssertionError() + if (element17 !in emptyCharSequence.indices != !range1.contains(element17)) throw AssertionError() + if (!(element17 in emptyCharSequence.indices) != !range1.contains(element17)) throw AssertionError() + if (!(element17 !in emptyCharSequence.indices) != range1.contains(element17)) throw AssertionError() +} + +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() + // no local optimizations + if (element18 in emptyCharSequence.indices != range1.contains(element18)) throw AssertionError() + if (element18 !in emptyCharSequence.indices != !range1.contains(element18)) throw AssertionError() + if (!(element18 in emptyCharSequence.indices) != !range1.contains(element18)) throw AssertionError() + if (!(element18 !in emptyCharSequence.indices) != range1.contains(element18)) throw AssertionError() +} + +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() + // no local optimizations + if (element19 in emptyCharSequence.indices != range1.contains(element19)) throw AssertionError() + if (element19 !in emptyCharSequence.indices != !range1.contains(element19)) throw AssertionError() + if (!(element19 in emptyCharSequence.indices) != !range1.contains(element19)) throw AssertionError() + if (!(element19 !in emptyCharSequence.indices) != range1.contains(element19)) throw AssertionError() +} + +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() + // no local optimizations + if (element20 in emptyCharSequence.indices != range1.contains(element20)) throw AssertionError() + if (element20 !in emptyCharSequence.indices != !range1.contains(element20)) throw AssertionError() + if (!(element20 in emptyCharSequence.indices) != !range1.contains(element20)) throw AssertionError() + if (!(element20 !in emptyCharSequence.indices) != range1.contains(element20)) throw AssertionError() +} + +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() + // no local optimizations + if (element21 in emptyCharSequence.indices != range1.contains(element21)) throw AssertionError() + if (element21 !in emptyCharSequence.indices != !range1.contains(element21)) throw AssertionError() + if (!(element21 in emptyCharSequence.indices) != !range1.contains(element21)) throw AssertionError() + if (!(element21 !in emptyCharSequence.indices) != range1.contains(element21)) throw AssertionError() +} + +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() + // no local optimizations + if (element22 in emptyCharSequence.indices != range1.contains(element22)) throw AssertionError() + if (element22 !in emptyCharSequence.indices != !range1.contains(element22)) throw AssertionError() + if (!(element22 in emptyCharSequence.indices) != !range1.contains(element22)) throw AssertionError() + if (!(element22 !in emptyCharSequence.indices) != range1.contains(element22)) throw AssertionError() +} + +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() + // no local optimizations + if (element23 in emptyCharSequence.indices != range1.contains(element23)) throw AssertionError() + if (element23 !in emptyCharSequence.indices != !range1.contains(element23)) throw AssertionError() + if (!(element23 in emptyCharSequence.indices) != !range1.contains(element23)) throw AssertionError() + 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/charUntil.kt b/compiler/testData/codegen/box/ranges/contains/generated/charUntil.kt new file mode 100644 index 00000000000..380a63eee82 --- /dev/null +++ b/compiler/testData/codegen/box/ranges/contains/generated/charUntil.kt @@ -0,0 +1,159 @@ +// Auto-generated by GenerateInRangeExpressionTestData. Do not edit! +// WITH_RUNTIME + + + +val range0 = '1' until '3' +val range1 = '3' until '1' + +val element0 = '0' +val element1 = '1' +val element2 = '2' +val element3 = '3' +val element4 = '4' + +fun box(): String { + testR0xE0() + testR0xE1() + testR0xE2() + testR0xE3() + testR0xE4() + testR1xE0() + testR1xE1() + testR1xE2() + testR1xE3() + testR1xE4() + return "OK" +} + +fun testR0xE0() { + // 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() + // no local optimizations + if (element0 in '1' until '3' != range0.contains(element0)) throw AssertionError() + if (element0 !in '1' until '3' != !range0.contains(element0)) throw AssertionError() + if (!(element0 in '1' until '3') != !range0.contains(element0)) throw AssertionError() + if (!(element0 !in '1' until '3') != range0.contains(element0)) throw AssertionError() +} + +fun testR0xE1() { + // 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() + // no local optimizations + if (element1 in '1' until '3' != range0.contains(element1)) throw AssertionError() + if (element1 !in '1' until '3' != !range0.contains(element1)) throw AssertionError() + if (!(element1 in '1' until '3') != !range0.contains(element1)) throw AssertionError() + if (!(element1 !in '1' until '3') != range0.contains(element1)) throw AssertionError() +} + +fun testR0xE2() { + // 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() + // no local optimizations + if (element2 in '1' until '3' != range0.contains(element2)) throw AssertionError() + if (element2 !in '1' until '3' != !range0.contains(element2)) throw AssertionError() + if (!(element2 in '1' until '3') != !range0.contains(element2)) throw AssertionError() + if (!(element2 !in '1' until '3') != range0.contains(element2)) throw AssertionError() +} + +fun testR0xE3() { + // 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 (element3 in '1' until '3' != range0.contains(element3)) throw AssertionError() + if (element3 !in '1' until '3' != !range0.contains(element3)) throw AssertionError() + if (!(element3 in '1' until '3') != !range0.contains(element3)) throw AssertionError() + if (!(element3 !in '1' until '3') != range0.contains(element3)) throw AssertionError() +} + +fun testR0xE4() { + // 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 (element4 in '1' until '3' != range0.contains(element4)) throw AssertionError() + if (element4 !in '1' until '3' != !range0.contains(element4)) throw AssertionError() + if (!(element4 in '1' until '3') != !range0.contains(element4)) throw AssertionError() + if (!(element4 !in '1' until '3') != range0.contains(element4)) throw AssertionError() +} + +fun testR1xE0() { + // 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() + // no local optimizations + if (element0 in '3' until '1' != range1.contains(element0)) throw AssertionError() + if (element0 !in '3' until '1' != !range1.contains(element0)) throw AssertionError() + if (!(element0 in '3' until '1') != !range1.contains(element0)) throw AssertionError() + if (!(element0 !in '3' until '1') != range1.contains(element0)) throw AssertionError() +} + +fun testR1xE1() { + // 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() + // no local optimizations + if (element1 in '3' until '1' != range1.contains(element1)) throw AssertionError() + if (element1 !in '3' until '1' != !range1.contains(element1)) throw AssertionError() + if (!(element1 in '3' until '1') != !range1.contains(element1)) throw AssertionError() + if (!(element1 !in '3' until '1') != range1.contains(element1)) throw AssertionError() +} + +fun testR1xE2() { + // 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() + // no local optimizations + if (element2 in '3' until '1' != range1.contains(element2)) throw AssertionError() + if (element2 !in '3' until '1' != !range1.contains(element2)) throw AssertionError() + if (!(element2 in '3' until '1') != !range1.contains(element2)) throw AssertionError() + if (!(element2 !in '3' until '1') != range1.contains(element2)) throw AssertionError() +} + +fun testR1xE3() { + // 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 (element3 in '3' until '1' != range1.contains(element3)) throw AssertionError() + if (element3 !in '3' until '1' != !range1.contains(element3)) throw AssertionError() + if (!(element3 in '3' until '1') != !range1.contains(element3)) throw AssertionError() + if (!(element3 !in '3' until '1') != range1.contains(element3)) throw AssertionError() +} + +fun testR1xE4() { + // 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 (element4 in '3' until '1' != range1.contains(element4)) throw AssertionError() + if (element4 !in '3' until '1' != !range1.contains(element4)) throw AssertionError() + if (!(element4 in '3' until '1') != !range1.contains(element4)) throw AssertionError() + if (!(element4 !in '3' until '1') != range1.contains(element4)) throw AssertionError() +} + + diff --git a/compiler/testData/codegen/box/ranges/contains/generated/collectionIndices.kt b/compiler/testData/codegen/box/ranges/contains/generated/collectionIndices.kt new file mode 100644 index 00000000000..952f5e7b4e9 --- /dev/null +++ b/compiler/testData/codegen/box/ranges/contains/generated/collectionIndices.kt @@ -0,0 +1,1059 @@ +// Auto-generated by GenerateInRangeExpressionTestData. Do not edit! +// WITH_RUNTIME + +val collection = listOf(1, 2, 3) +val emptyCollection = listOf() + +val range0 = collection.indices +val range1 = emptyCollection.indices + +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() + +fun box(): String { + testR0xE0() + testR0xE1() + testR0xE2() + testR0xE3() + testR0xE4() + testR0xE5() + testR0xE6() + testR0xE7() + testR0xE8() + 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() + testR1xE3() + testR1xE4() + testR1xE5() + testR1xE6() + testR1xE7() + testR1xE8() + 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 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 (element0 in collection.indices != range0.contains(element0)) throw AssertionError() + if (element0 !in collection.indices != !range0.contains(element0)) throw AssertionError() + if (!(element0 in collection.indices) != !range0.contains(element0)) throw AssertionError() + if (!(element0 !in collection.indices) != range0.contains(element0)) throw AssertionError() +} + +fun testR0xE1() { + // 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() + // no local optimizations + if (element1 in collection.indices != range0.contains(element1)) throw AssertionError() + if (element1 !in collection.indices != !range0.contains(element1)) throw AssertionError() + if (!(element1 in collection.indices) != !range0.contains(element1)) throw AssertionError() + if (!(element1 !in collection.indices) != range0.contains(element1)) throw AssertionError() +} + +fun testR0xE2() { + // 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() + // no local optimizations + if (element2 in collection.indices != range0.contains(element2)) throw AssertionError() + if (element2 !in collection.indices != !range0.contains(element2)) throw AssertionError() + if (!(element2 in collection.indices) != !range0.contains(element2)) throw AssertionError() + if (!(element2 !in collection.indices) != range0.contains(element2)) throw AssertionError() +} + +fun testR0xE3() { + // 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() + // no local optimizations + if (element3 in collection.indices != range0.contains(element3)) throw AssertionError() + if (element3 !in collection.indices != !range0.contains(element3)) throw AssertionError() + if (!(element3 in collection.indices) != !range0.contains(element3)) throw AssertionError() + if (!(element3 !in collection.indices) != range0.contains(element3)) throw AssertionError() +} + +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() + // no local optimizations + if (element4 in collection.indices != range0.contains(element4)) throw AssertionError() + if (element4 !in collection.indices != !range0.contains(element4)) throw AssertionError() + if (!(element4 in collection.indices) != !range0.contains(element4)) throw AssertionError() + if (!(element4 !in collection.indices) != range0.contains(element4)) throw AssertionError() +} + +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() + // no local optimizations + if (element5 in collection.indices != range0.contains(element5)) throw AssertionError() + if (element5 !in collection.indices != !range0.contains(element5)) throw AssertionError() + if (!(element5 in collection.indices) != !range0.contains(element5)) throw AssertionError() + if (!(element5 !in collection.indices) != range0.contains(element5)) throw AssertionError() +} + +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() + // no local optimizations + if (element6 in collection.indices != range0.contains(element6)) throw AssertionError() + if (element6 !in collection.indices != !range0.contains(element6)) throw AssertionError() + if (!(element6 in collection.indices) != !range0.contains(element6)) throw AssertionError() + if (!(element6 !in collection.indices) != range0.contains(element6)) throw AssertionError() +} + +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() + // no local optimizations + if (element7 in collection.indices != range0.contains(element7)) throw AssertionError() + if (element7 !in collection.indices != !range0.contains(element7)) throw AssertionError() + if (!(element7 in collection.indices) != !range0.contains(element7)) throw AssertionError() + if (!(element7 !in collection.indices) != range0.contains(element7)) throw AssertionError() +} + +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() + // no local optimizations + if (element8 in collection.indices != range0.contains(element8)) throw AssertionError() + if (element8 !in collection.indices != !range0.contains(element8)) throw AssertionError() + if (!(element8 in collection.indices) != !range0.contains(element8)) throw AssertionError() + if (!(element8 !in collection.indices) != range0.contains(element8)) throw AssertionError() +} + +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() + // no local optimizations + if (element9 in collection.indices != range0.contains(element9)) throw AssertionError() + if (element9 !in collection.indices != !range0.contains(element9)) throw AssertionError() + if (!(element9 in collection.indices) != !range0.contains(element9)) throw AssertionError() + if (!(element9 !in collection.indices) != range0.contains(element9)) throw AssertionError() +} + +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() + // no local optimizations + if (element10 in collection.indices != range0.contains(element10)) throw AssertionError() + if (element10 !in collection.indices != !range0.contains(element10)) throw AssertionError() + if (!(element10 in collection.indices) != !range0.contains(element10)) throw AssertionError() + if (!(element10 !in collection.indices) != range0.contains(element10)) throw AssertionError() +} + +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() + // no local optimizations + if (element11 in collection.indices != range0.contains(element11)) throw AssertionError() + if (element11 !in collection.indices != !range0.contains(element11)) throw AssertionError() + if (!(element11 in collection.indices) != !range0.contains(element11)) throw AssertionError() + if (!(element11 !in collection.indices) != range0.contains(element11)) throw AssertionError() +} + +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() + // no local optimizations + if (element12 in collection.indices != range0.contains(element12)) throw AssertionError() + if (element12 !in collection.indices != !range0.contains(element12)) throw AssertionError() + if (!(element12 in collection.indices) != !range0.contains(element12)) throw AssertionError() + if (!(element12 !in collection.indices) != range0.contains(element12)) throw AssertionError() +} + +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() + // no local optimizations + if (element13 in collection.indices != range0.contains(element13)) throw AssertionError() + if (element13 !in collection.indices != !range0.contains(element13)) throw AssertionError() + if (!(element13 in collection.indices) != !range0.contains(element13)) throw AssertionError() + if (!(element13 !in collection.indices) != range0.contains(element13)) throw AssertionError() +} + +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() + // no local optimizations + if (element14 in collection.indices != range0.contains(element14)) throw AssertionError() + if (element14 !in collection.indices != !range0.contains(element14)) throw AssertionError() + if (!(element14 in collection.indices) != !range0.contains(element14)) throw AssertionError() + if (!(element14 !in collection.indices) != range0.contains(element14)) throw AssertionError() +} + +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() + // no local optimizations + if (element15 in collection.indices != range0.contains(element15)) throw AssertionError() + if (element15 !in collection.indices != !range0.contains(element15)) throw AssertionError() + if (!(element15 in collection.indices) != !range0.contains(element15)) throw AssertionError() + if (!(element15 !in collection.indices) != range0.contains(element15)) throw AssertionError() +} + +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() + // no local optimizations + if (element16 in collection.indices != range0.contains(element16)) throw AssertionError() + if (element16 !in collection.indices != !range0.contains(element16)) throw AssertionError() + if (!(element16 in collection.indices) != !range0.contains(element16)) throw AssertionError() + if (!(element16 !in collection.indices) != range0.contains(element16)) throw AssertionError() +} + +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() + // no local optimizations + if (element17 in collection.indices != range0.contains(element17)) throw AssertionError() + if (element17 !in collection.indices != !range0.contains(element17)) throw AssertionError() + if (!(element17 in collection.indices) != !range0.contains(element17)) throw AssertionError() + if (!(element17 !in collection.indices) != range0.contains(element17)) throw AssertionError() +} + +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() + // no local optimizations + if (element18 in collection.indices != range0.contains(element18)) throw AssertionError() + if (element18 !in collection.indices != !range0.contains(element18)) throw AssertionError() + if (!(element18 in collection.indices) != !range0.contains(element18)) throw AssertionError() + if (!(element18 !in collection.indices) != range0.contains(element18)) throw AssertionError() +} + +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() + // no local optimizations + if (element19 in collection.indices != range0.contains(element19)) throw AssertionError() + if (element19 !in collection.indices != !range0.contains(element19)) throw AssertionError() + if (!(element19 in collection.indices) != !range0.contains(element19)) throw AssertionError() + if (!(element19 !in collection.indices) != range0.contains(element19)) throw AssertionError() +} + +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() + // no local optimizations + if (element20 in collection.indices != range0.contains(element20)) throw AssertionError() + if (element20 !in collection.indices != !range0.contains(element20)) throw AssertionError() + if (!(element20 in collection.indices) != !range0.contains(element20)) throw AssertionError() + if (!(element20 !in collection.indices) != range0.contains(element20)) throw AssertionError() +} + +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() + // no local optimizations + if (element21 in collection.indices != range0.contains(element21)) throw AssertionError() + if (element21 !in collection.indices != !range0.contains(element21)) throw AssertionError() + if (!(element21 in collection.indices) != !range0.contains(element21)) throw AssertionError() + if (!(element21 !in collection.indices) != range0.contains(element21)) throw AssertionError() +} + +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() + // no local optimizations + if (element22 in collection.indices != range0.contains(element22)) throw AssertionError() + if (element22 !in collection.indices != !range0.contains(element22)) throw AssertionError() + if (!(element22 in collection.indices) != !range0.contains(element22)) throw AssertionError() + if (!(element22 !in collection.indices) != range0.contains(element22)) throw AssertionError() +} + +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() +} + +fun testR1xE0() { + // 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() + // no local optimizations + if (element0 in emptyCollection.indices != range1.contains(element0)) throw AssertionError() + if (element0 !in emptyCollection.indices != !range1.contains(element0)) throw AssertionError() + if (!(element0 in emptyCollection.indices) != !range1.contains(element0)) throw AssertionError() + if (!(element0 !in emptyCollection.indices) != range1.contains(element0)) throw AssertionError() +} + +fun testR1xE1() { + // 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() + // no local optimizations + if (element1 in emptyCollection.indices != range1.contains(element1)) throw AssertionError() + if (element1 !in emptyCollection.indices != !range1.contains(element1)) throw AssertionError() + if (!(element1 in emptyCollection.indices) != !range1.contains(element1)) throw AssertionError() + if (!(element1 !in emptyCollection.indices) != range1.contains(element1)) throw AssertionError() +} + +fun testR1xE2() { + // 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() + // no local optimizations + if (element2 in emptyCollection.indices != range1.contains(element2)) throw AssertionError() + if (element2 !in emptyCollection.indices != !range1.contains(element2)) throw AssertionError() + if (!(element2 in emptyCollection.indices) != !range1.contains(element2)) throw AssertionError() + if (!(element2 !in emptyCollection.indices) != range1.contains(element2)) throw AssertionError() +} + +fun testR1xE3() { + // 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() + // no local optimizations + if (element3 in emptyCollection.indices != range1.contains(element3)) throw AssertionError() + if (element3 !in emptyCollection.indices != !range1.contains(element3)) throw AssertionError() + if (!(element3 in emptyCollection.indices) != !range1.contains(element3)) throw AssertionError() + if (!(element3 !in emptyCollection.indices) != range1.contains(element3)) throw AssertionError() +} + +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() + // no local optimizations + if (element4 in emptyCollection.indices != range1.contains(element4)) throw AssertionError() + if (element4 !in emptyCollection.indices != !range1.contains(element4)) throw AssertionError() + if (!(element4 in emptyCollection.indices) != !range1.contains(element4)) throw AssertionError() + if (!(element4 !in emptyCollection.indices) != range1.contains(element4)) throw AssertionError() +} + +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() + // no local optimizations + if (element5 in emptyCollection.indices != range1.contains(element5)) throw AssertionError() + if (element5 !in emptyCollection.indices != !range1.contains(element5)) throw AssertionError() + if (!(element5 in emptyCollection.indices) != !range1.contains(element5)) throw AssertionError() + if (!(element5 !in emptyCollection.indices) != range1.contains(element5)) throw AssertionError() +} + +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() + // no local optimizations + if (element6 in emptyCollection.indices != range1.contains(element6)) throw AssertionError() + if (element6 !in emptyCollection.indices != !range1.contains(element6)) throw AssertionError() + if (!(element6 in emptyCollection.indices) != !range1.contains(element6)) throw AssertionError() + if (!(element6 !in emptyCollection.indices) != range1.contains(element6)) throw AssertionError() +} + +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() + // no local optimizations + if (element7 in emptyCollection.indices != range1.contains(element7)) throw AssertionError() + if (element7 !in emptyCollection.indices != !range1.contains(element7)) throw AssertionError() + if (!(element7 in emptyCollection.indices) != !range1.contains(element7)) throw AssertionError() + if (!(element7 !in emptyCollection.indices) != range1.contains(element7)) throw AssertionError() +} + +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() + // no local optimizations + if (element8 in emptyCollection.indices != range1.contains(element8)) throw AssertionError() + if (element8 !in emptyCollection.indices != !range1.contains(element8)) throw AssertionError() + if (!(element8 in emptyCollection.indices) != !range1.contains(element8)) throw AssertionError() + if (!(element8 !in emptyCollection.indices) != range1.contains(element8)) throw AssertionError() +} + +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() + // no local optimizations + if (element9 in emptyCollection.indices != range1.contains(element9)) throw AssertionError() + if (element9 !in emptyCollection.indices != !range1.contains(element9)) throw AssertionError() + if (!(element9 in emptyCollection.indices) != !range1.contains(element9)) throw AssertionError() + if (!(element9 !in emptyCollection.indices) != range1.contains(element9)) throw AssertionError() +} + +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() + // no local optimizations + if (element10 in emptyCollection.indices != range1.contains(element10)) throw AssertionError() + if (element10 !in emptyCollection.indices != !range1.contains(element10)) throw AssertionError() + if (!(element10 in emptyCollection.indices) != !range1.contains(element10)) throw AssertionError() + if (!(element10 !in emptyCollection.indices) != range1.contains(element10)) throw AssertionError() +} + +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() + // no local optimizations + if (element11 in emptyCollection.indices != range1.contains(element11)) throw AssertionError() + if (element11 !in emptyCollection.indices != !range1.contains(element11)) throw AssertionError() + if (!(element11 in emptyCollection.indices) != !range1.contains(element11)) throw AssertionError() + if (!(element11 !in emptyCollection.indices) != range1.contains(element11)) throw AssertionError() +} + +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() + // no local optimizations + if (element12 in emptyCollection.indices != range1.contains(element12)) throw AssertionError() + if (element12 !in emptyCollection.indices != !range1.contains(element12)) throw AssertionError() + if (!(element12 in emptyCollection.indices) != !range1.contains(element12)) throw AssertionError() + if (!(element12 !in emptyCollection.indices) != range1.contains(element12)) throw AssertionError() +} + +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() + // no local optimizations + if (element13 in emptyCollection.indices != range1.contains(element13)) throw AssertionError() + if (element13 !in emptyCollection.indices != !range1.contains(element13)) throw AssertionError() + if (!(element13 in emptyCollection.indices) != !range1.contains(element13)) throw AssertionError() + if (!(element13 !in emptyCollection.indices) != range1.contains(element13)) throw AssertionError() +} + +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() + // no local optimizations + if (element14 in emptyCollection.indices != range1.contains(element14)) throw AssertionError() + if (element14 !in emptyCollection.indices != !range1.contains(element14)) throw AssertionError() + if (!(element14 in emptyCollection.indices) != !range1.contains(element14)) throw AssertionError() + if (!(element14 !in emptyCollection.indices) != range1.contains(element14)) throw AssertionError() +} + +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() + // no local optimizations + if (element15 in emptyCollection.indices != range1.contains(element15)) throw AssertionError() + if (element15 !in emptyCollection.indices != !range1.contains(element15)) throw AssertionError() + if (!(element15 in emptyCollection.indices) != !range1.contains(element15)) throw AssertionError() + if (!(element15 !in emptyCollection.indices) != range1.contains(element15)) throw AssertionError() +} + +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() + // no local optimizations + if (element16 in emptyCollection.indices != range1.contains(element16)) throw AssertionError() + if (element16 !in emptyCollection.indices != !range1.contains(element16)) throw AssertionError() + if (!(element16 in emptyCollection.indices) != !range1.contains(element16)) throw AssertionError() + if (!(element16 !in emptyCollection.indices) != range1.contains(element16)) throw AssertionError() +} + +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() + // no local optimizations + if (element17 in emptyCollection.indices != range1.contains(element17)) throw AssertionError() + if (element17 !in emptyCollection.indices != !range1.contains(element17)) throw AssertionError() + if (!(element17 in emptyCollection.indices) != !range1.contains(element17)) throw AssertionError() + if (!(element17 !in emptyCollection.indices) != range1.contains(element17)) throw AssertionError() +} + +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() + // no local optimizations + if (element18 in emptyCollection.indices != range1.contains(element18)) throw AssertionError() + if (element18 !in emptyCollection.indices != !range1.contains(element18)) throw AssertionError() + if (!(element18 in emptyCollection.indices) != !range1.contains(element18)) throw AssertionError() + if (!(element18 !in emptyCollection.indices) != range1.contains(element18)) throw AssertionError() +} + +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() + // no local optimizations + if (element19 in emptyCollection.indices != range1.contains(element19)) throw AssertionError() + if (element19 !in emptyCollection.indices != !range1.contains(element19)) throw AssertionError() + if (!(element19 in emptyCollection.indices) != !range1.contains(element19)) throw AssertionError() + if (!(element19 !in emptyCollection.indices) != range1.contains(element19)) throw AssertionError() +} + +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() + // no local optimizations + if (element20 in emptyCollection.indices != range1.contains(element20)) throw AssertionError() + if (element20 !in emptyCollection.indices != !range1.contains(element20)) throw AssertionError() + if (!(element20 in emptyCollection.indices) != !range1.contains(element20)) throw AssertionError() + if (!(element20 !in emptyCollection.indices) != range1.contains(element20)) throw AssertionError() +} + +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() + // no local optimizations + if (element21 in emptyCollection.indices != range1.contains(element21)) throw AssertionError() + if (element21 !in emptyCollection.indices != !range1.contains(element21)) throw AssertionError() + if (!(element21 in emptyCollection.indices) != !range1.contains(element21)) throw AssertionError() + if (!(element21 !in emptyCollection.indices) != range1.contains(element21)) throw AssertionError() +} + +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() + // no local optimizations + if (element22 in emptyCollection.indices != range1.contains(element22)) throw AssertionError() + if (element22 !in emptyCollection.indices != !range1.contains(element22)) throw AssertionError() + if (!(element22 in emptyCollection.indices) != !range1.contains(element22)) throw AssertionError() + if (!(element22 !in emptyCollection.indices) != range1.contains(element22)) throw AssertionError() +} + +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() + // no local optimizations + if (element23 in emptyCollection.indices != range1.contains(element23)) throw AssertionError() + if (element23 !in emptyCollection.indices != !range1.contains(element23)) throw AssertionError() + if (!(element23 in emptyCollection.indices) != !range1.contains(element23)) throw AssertionError() + 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 new file mode 100644 index 00000000000..aee5167c174 --- /dev/null +++ b/compiler/testData/codegen/box/ranges/contains/generated/doubleRangeLiteral.kt @@ -0,0 +1,1058 @@ +// Auto-generated by GenerateInRangeExpressionTestData. Do not edit! +// WITH_RUNTIME + + + +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() + +fun box(): String { + testR0xE0() + testR0xE1() + testR0xE2() + testR0xE3() + testR0xE4() + testR0xE5() + testR0xE6() + testR0xE7() + testR0xE8() + 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() + testR1xE3() + testR1xE4() + testR1xE5() + testR1xE6() + testR1xE7() + testR1xE8() + 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() + // 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() + if (!(element0 in 1.0 .. 3.0) != !range0.contains(element0)) throw AssertionError() + if (!(element0 !in 1.0 .. 3.0) != range0.contains(element0)) throw AssertionError() +} + +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() + // 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() + if (!(element1 in 1.0 .. 3.0) != !range0.contains(element1)) throw AssertionError() + if (!(element1 !in 1.0 .. 3.0) != range0.contains(element1)) throw AssertionError() +} + +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() + // 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() + if (!(element2 in 1.0 .. 3.0) != !range0.contains(element2)) throw AssertionError() + if (!(element2 !in 1.0 .. 3.0) != range0.contains(element2)) throw AssertionError() +} + +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() + // 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() + if (!(element3 in 1.0 .. 3.0) != !range0.contains(element3)) throw AssertionError() + if (!(element3 !in 1.0 .. 3.0) != range0.contains(element3)) throw AssertionError() +} + +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() + // 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() + if (!(element4 in 1.0 .. 3.0) != !range0.contains(element4)) throw AssertionError() + if (!(element4 !in 1.0 .. 3.0) != range0.contains(element4)) throw AssertionError() +} + +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() + // 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() + if (!(element5 in 1.0 .. 3.0) != !range0.contains(element5)) throw AssertionError() + if (!(element5 !in 1.0 .. 3.0) != range0.contains(element5)) throw AssertionError() +} + +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() + // 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() + if (!(element6 in 1.0 .. 3.0) != !range0.contains(element6)) throw AssertionError() + if (!(element6 !in 1.0 .. 3.0) != range0.contains(element6)) throw AssertionError() +} + +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() + // 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() + if (!(element7 in 1.0 .. 3.0) != !range0.contains(element7)) throw AssertionError() + if (!(element7 !in 1.0 .. 3.0) != range0.contains(element7)) throw AssertionError() +} + +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() + // 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() + if (!(element8 in 1.0 .. 3.0) != !range0.contains(element8)) throw AssertionError() + if (!(element8 !in 1.0 .. 3.0) != range0.contains(element8)) throw AssertionError() +} + +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() + // 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() + if (!(element9 in 1.0 .. 3.0) != !range0.contains(element9)) throw AssertionError() + if (!(element9 !in 1.0 .. 3.0) != range0.contains(element9)) throw AssertionError() +} + +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() + // 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() + if (!(element10 in 1.0 .. 3.0) != !range0.contains(element10)) throw AssertionError() + if (!(element10 !in 1.0 .. 3.0) != range0.contains(element10)) throw AssertionError() +} + +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() + // 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() + if (!(element11 in 1.0 .. 3.0) != !range0.contains(element11)) throw AssertionError() + 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() + // 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() + if (!(element0 in 3.0 .. 1.0) != !range1.contains(element0)) throw AssertionError() + if (!(element0 !in 3.0 .. 1.0) != range1.contains(element0)) throw AssertionError() +} + +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() + // 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() + if (!(element1 in 3.0 .. 1.0) != !range1.contains(element1)) throw AssertionError() + if (!(element1 !in 3.0 .. 1.0) != range1.contains(element1)) throw AssertionError() +} + +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() + // 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() + if (!(element2 in 3.0 .. 1.0) != !range1.contains(element2)) throw AssertionError() + if (!(element2 !in 3.0 .. 1.0) != range1.contains(element2)) throw AssertionError() +} + +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() + // 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() + if (!(element3 in 3.0 .. 1.0) != !range1.contains(element3)) throw AssertionError() + if (!(element3 !in 3.0 .. 1.0) != range1.contains(element3)) throw AssertionError() +} + +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() + // 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() + if (!(element4 in 3.0 .. 1.0) != !range1.contains(element4)) throw AssertionError() + if (!(element4 !in 3.0 .. 1.0) != range1.contains(element4)) throw AssertionError() +} + +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() + // 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() + if (!(element5 in 3.0 .. 1.0) != !range1.contains(element5)) throw AssertionError() + if (!(element5 !in 3.0 .. 1.0) != range1.contains(element5)) throw AssertionError() +} + +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() + // 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() + if (!(element6 in 3.0 .. 1.0) != !range1.contains(element6)) throw AssertionError() + if (!(element6 !in 3.0 .. 1.0) != range1.contains(element6)) throw AssertionError() +} + +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() + // 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() + if (!(element7 in 3.0 .. 1.0) != !range1.contains(element7)) throw AssertionError() + if (!(element7 !in 3.0 .. 1.0) != range1.contains(element7)) throw AssertionError() +} + +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() + // 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() + if (!(element8 in 3.0 .. 1.0) != !range1.contains(element8)) throw AssertionError() + if (!(element8 !in 3.0 .. 1.0) != range1.contains(element8)) throw AssertionError() +} + +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() + // 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() + if (!(element9 in 3.0 .. 1.0) != !range1.contains(element9)) throw AssertionError() + if (!(element9 !in 3.0 .. 1.0) != range1.contains(element9)) throw AssertionError() +} + +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() + // 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() + if (!(element10 in 3.0 .. 1.0) != !range1.contains(element10)) throw AssertionError() + if (!(element10 !in 3.0 .. 1.0) != range1.contains(element10)) throw AssertionError() +} + +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() + // 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() + if (!(element11 in 3.0 .. 1.0) != !range1.contains(element11)) throw AssertionError() + 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 new file mode 100644 index 00000000000..9e098f9c705 --- /dev/null +++ b/compiler/testData/codegen/box/ranges/contains/generated/floatRangeLiteral.kt @@ -0,0 +1,1058 @@ +// Auto-generated by GenerateInRangeExpressionTestData. Do not edit! +// WITH_RUNTIME + + + +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() + +fun box(): String { + testR0xE0() + testR0xE1() + testR0xE2() + testR0xE3() + testR0xE4() + testR0xE5() + testR0xE6() + testR0xE7() + testR0xE8() + 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() + testR1xE3() + testR1xE4() + testR1xE5() + testR1xE6() + testR1xE7() + testR1xE8() + 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() + // 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() + if (!(element0 in 1.0F .. 3.0F) != !range0.contains(element0)) throw AssertionError() + if (!(element0 !in 1.0F .. 3.0F) != range0.contains(element0)) throw AssertionError() +} + +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() + // 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() + if (!(element1 in 1.0F .. 3.0F) != !range0.contains(element1)) throw AssertionError() + if (!(element1 !in 1.0F .. 3.0F) != range0.contains(element1)) throw AssertionError() +} + +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() + // 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() + if (!(element2 in 1.0F .. 3.0F) != !range0.contains(element2)) throw AssertionError() + if (!(element2 !in 1.0F .. 3.0F) != range0.contains(element2)) throw AssertionError() +} + +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() + // 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() + if (!(element3 in 1.0F .. 3.0F) != !range0.contains(element3)) throw AssertionError() + if (!(element3 !in 1.0F .. 3.0F) != range0.contains(element3)) throw AssertionError() +} + +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() + // 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() + if (!(element4 in 1.0F .. 3.0F) != !range0.contains(element4)) throw AssertionError() + if (!(element4 !in 1.0F .. 3.0F) != range0.contains(element4)) throw AssertionError() +} + +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() + // 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() + if (!(element5 in 1.0F .. 3.0F) != !range0.contains(element5)) throw AssertionError() + if (!(element5 !in 1.0F .. 3.0F) != range0.contains(element5)) throw AssertionError() +} + +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() + // 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() + if (!(element6 in 1.0F .. 3.0F) != !range0.contains(element6)) throw AssertionError() + if (!(element6 !in 1.0F .. 3.0F) != range0.contains(element6)) throw AssertionError() +} + +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() + // 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() + if (!(element7 in 1.0F .. 3.0F) != !range0.contains(element7)) throw AssertionError() + if (!(element7 !in 1.0F .. 3.0F) != range0.contains(element7)) throw AssertionError() +} + +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() + // 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() + if (!(element8 in 1.0F .. 3.0F) != !range0.contains(element8)) throw AssertionError() + if (!(element8 !in 1.0F .. 3.0F) != range0.contains(element8)) throw AssertionError() +} + +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() + // 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() + if (!(element9 in 1.0F .. 3.0F) != !range0.contains(element9)) throw AssertionError() + if (!(element9 !in 1.0F .. 3.0F) != range0.contains(element9)) throw AssertionError() +} + +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() + // 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() + if (!(element10 in 1.0F .. 3.0F) != !range0.contains(element10)) throw AssertionError() + if (!(element10 !in 1.0F .. 3.0F) != range0.contains(element10)) throw AssertionError() +} + +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() + // 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() + if (!(element11 in 1.0F .. 3.0F) != !range0.contains(element11)) throw AssertionError() + 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() + // 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() + if (!(element0 in 3.0F .. 1.0F) != !range1.contains(element0)) throw AssertionError() + if (!(element0 !in 3.0F .. 1.0F) != range1.contains(element0)) throw AssertionError() +} + +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() + // 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() + if (!(element1 in 3.0F .. 1.0F) != !range1.contains(element1)) throw AssertionError() + if (!(element1 !in 3.0F .. 1.0F) != range1.contains(element1)) throw AssertionError() +} + +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() + // 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() + if (!(element2 in 3.0F .. 1.0F) != !range1.contains(element2)) throw AssertionError() + if (!(element2 !in 3.0F .. 1.0F) != range1.contains(element2)) throw AssertionError() +} + +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() + // 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() + if (!(element3 in 3.0F .. 1.0F) != !range1.contains(element3)) throw AssertionError() + if (!(element3 !in 3.0F .. 1.0F) != range1.contains(element3)) throw AssertionError() +} + +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() + // 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() + if (!(element4 in 3.0F .. 1.0F) != !range1.contains(element4)) throw AssertionError() + if (!(element4 !in 3.0F .. 1.0F) != range1.contains(element4)) throw AssertionError() +} + +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() + // 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() + if (!(element5 in 3.0F .. 1.0F) != !range1.contains(element5)) throw AssertionError() + if (!(element5 !in 3.0F .. 1.0F) != range1.contains(element5)) throw AssertionError() +} + +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() + // 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() + if (!(element6 in 3.0F .. 1.0F) != !range1.contains(element6)) throw AssertionError() + if (!(element6 !in 3.0F .. 1.0F) != range1.contains(element6)) throw AssertionError() +} + +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() + // 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() + if (!(element7 in 3.0F .. 1.0F) != !range1.contains(element7)) throw AssertionError() + if (!(element7 !in 3.0F .. 1.0F) != range1.contains(element7)) throw AssertionError() +} + +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() + // 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() + if (!(element8 in 3.0F .. 1.0F) != !range1.contains(element8)) throw AssertionError() + if (!(element8 !in 3.0F .. 1.0F) != range1.contains(element8)) throw AssertionError() +} + +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() + // 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() + if (!(element9 in 3.0F .. 1.0F) != !range1.contains(element9)) throw AssertionError() + if (!(element9 !in 3.0F .. 1.0F) != range1.contains(element9)) throw AssertionError() +} + +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() + // 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() + if (!(element10 in 3.0F .. 1.0F) != !range1.contains(element10)) throw AssertionError() + if (!(element10 !in 3.0F .. 1.0F) != range1.contains(element10)) throw AssertionError() +} + +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() + // 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() + if (!(element11 in 3.0F .. 1.0F) != !range1.contains(element11)) throw AssertionError() + 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/intDownTo.kt b/compiler/testData/codegen/box/ranges/contains/generated/intDownTo.kt new file mode 100644 index 00000000000..5bda3e06c2f --- /dev/null +++ b/compiler/testData/codegen/box/ranges/contains/generated/intDownTo.kt @@ -0,0 +1,43 @@ +// Auto-generated by GenerateInRangeExpressionTestData. Do not edit! +// WITH_RUNTIME + + + +val range0 = 3 downTo 1 +val range1 = 1 downTo 3 + +val element0 = 1 + +fun box(): String { + testR0xE0() + testR1xE0() + return "OK" +} + +fun testR0xE0() { + // with possible local optimizations + if (1 in 3 downTo 1 != range0.contains(1)) throw AssertionError() + if (1 !in 3 downTo 1 != !range0.contains(1)) throw AssertionError() + if (!(1 in 3 downTo 1) != !range0.contains(1)) throw AssertionError() + if (!(1 !in 3 downTo 1) != range0.contains(1)) throw AssertionError() + // no local optimizations + if (element0 in 3 downTo 1 != range0.contains(element0)) throw AssertionError() + if (element0 !in 3 downTo 1 != !range0.contains(element0)) throw AssertionError() + if (!(element0 in 3 downTo 1) != !range0.contains(element0)) throw AssertionError() + if (!(element0 !in 3 downTo 1) != range0.contains(element0)) throw AssertionError() +} + +fun testR1xE0() { + // with possible local optimizations + if (1 in 1 downTo 3 != range1.contains(1)) throw AssertionError() + if (1 !in 1 downTo 3 != !range1.contains(1)) throw AssertionError() + if (!(1 in 1 downTo 3) != !range1.contains(1)) throw AssertionError() + if (!(1 !in 1 downTo 3) != range1.contains(1)) throw AssertionError() + // no local optimizations + if (element0 in 1 downTo 3 != range1.contains(element0)) throw AssertionError() + if (element0 !in 1 downTo 3 != !range1.contains(element0)) throw AssertionError() + if (!(element0 in 1 downTo 3) != !range1.contains(element0)) throw AssertionError() + if (!(element0 !in 1 downTo 3) != range1.contains(element0)) throw AssertionError() +} + + diff --git a/compiler/testData/codegen/box/ranges/contains/generated/intRangeLiteral.kt b/compiler/testData/codegen/box/ranges/contains/generated/intRangeLiteral.kt new file mode 100644 index 00000000000..5552b83dc8d --- /dev/null +++ b/compiler/testData/codegen/box/ranges/contains/generated/intRangeLiteral.kt @@ -0,0 +1,1058 @@ +// Auto-generated by GenerateInRangeExpressionTestData. Do not edit! +// WITH_RUNTIME + + + +val range0 = 1 .. 3 +val range1 = 3 .. 1 + +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() + +fun box(): String { + testR0xE0() + testR0xE1() + testR0xE2() + testR0xE3() + testR0xE4() + testR0xE5() + testR0xE6() + testR0xE7() + testR0xE8() + 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() + testR1xE3() + testR1xE4() + testR1xE5() + testR1xE6() + testR1xE7() + testR1xE8() + 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 .. 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 (element0 in 1 .. 3 != range0.contains(element0)) throw AssertionError() + if (element0 !in 1 .. 3 != !range0.contains(element0)) throw AssertionError() + if (!(element0 in 1 .. 3) != !range0.contains(element0)) throw AssertionError() + if (!(element0 !in 1 .. 3) != range0.contains(element0)) throw AssertionError() +} + +fun testR0xE1() { + // 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() + // no local optimizations + if (element1 in 1 .. 3 != range0.contains(element1)) throw AssertionError() + if (element1 !in 1 .. 3 != !range0.contains(element1)) throw AssertionError() + if (!(element1 in 1 .. 3) != !range0.contains(element1)) throw AssertionError() + if (!(element1 !in 1 .. 3) != range0.contains(element1)) throw AssertionError() +} + +fun testR0xE2() { + // 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() + // no local optimizations + if (element2 in 1 .. 3 != range0.contains(element2)) throw AssertionError() + if (element2 !in 1 .. 3 != !range0.contains(element2)) throw AssertionError() + if (!(element2 in 1 .. 3) != !range0.contains(element2)) throw AssertionError() + if (!(element2 !in 1 .. 3) != range0.contains(element2)) throw AssertionError() +} + +fun testR0xE3() { + // 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() + // no local optimizations + if (element3 in 1 .. 3 != range0.contains(element3)) throw AssertionError() + if (element3 !in 1 .. 3 != !range0.contains(element3)) throw AssertionError() + if (!(element3 in 1 .. 3) != !range0.contains(element3)) throw AssertionError() + if (!(element3 !in 1 .. 3) != range0.contains(element3)) throw AssertionError() +} + +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() + // no local optimizations + if (element4 in 1 .. 3 != range0.contains(element4)) throw AssertionError() + if (element4 !in 1 .. 3 != !range0.contains(element4)) throw AssertionError() + if (!(element4 in 1 .. 3) != !range0.contains(element4)) throw AssertionError() + if (!(element4 !in 1 .. 3) != range0.contains(element4)) throw AssertionError() +} + +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() + // no local optimizations + if (element5 in 1 .. 3 != range0.contains(element5)) throw AssertionError() + if (element5 !in 1 .. 3 != !range0.contains(element5)) throw AssertionError() + if (!(element5 in 1 .. 3) != !range0.contains(element5)) throw AssertionError() + if (!(element5 !in 1 .. 3) != range0.contains(element5)) throw AssertionError() +} + +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() + // no local optimizations + if (element6 in 1 .. 3 != range0.contains(element6)) throw AssertionError() + if (element6 !in 1 .. 3 != !range0.contains(element6)) throw AssertionError() + if (!(element6 in 1 .. 3) != !range0.contains(element6)) throw AssertionError() + if (!(element6 !in 1 .. 3) != range0.contains(element6)) throw AssertionError() +} + +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() + // no local optimizations + if (element7 in 1 .. 3 != range0.contains(element7)) throw AssertionError() + if (element7 !in 1 .. 3 != !range0.contains(element7)) throw AssertionError() + if (!(element7 in 1 .. 3) != !range0.contains(element7)) throw AssertionError() + if (!(element7 !in 1 .. 3) != range0.contains(element7)) throw AssertionError() +} + +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() + // no local optimizations + if (element8 in 1 .. 3 != range0.contains(element8)) throw AssertionError() + if (element8 !in 1 .. 3 != !range0.contains(element8)) throw AssertionError() + if (!(element8 in 1 .. 3) != !range0.contains(element8)) throw AssertionError() + if (!(element8 !in 1 .. 3) != range0.contains(element8)) throw AssertionError() +} + +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() + // no local optimizations + if (element9 in 1 .. 3 != range0.contains(element9)) throw AssertionError() + if (element9 !in 1 .. 3 != !range0.contains(element9)) throw AssertionError() + if (!(element9 in 1 .. 3) != !range0.contains(element9)) throw AssertionError() + if (!(element9 !in 1 .. 3) != range0.contains(element9)) throw AssertionError() +} + +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() + // no local optimizations + if (element10 in 1 .. 3 != range0.contains(element10)) throw AssertionError() + if (element10 !in 1 .. 3 != !range0.contains(element10)) throw AssertionError() + if (!(element10 in 1 .. 3) != !range0.contains(element10)) throw AssertionError() + if (!(element10 !in 1 .. 3) != range0.contains(element10)) throw AssertionError() +} + +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() + // no local optimizations + if (element11 in 1 .. 3 != range0.contains(element11)) throw AssertionError() + if (element11 !in 1 .. 3 != !range0.contains(element11)) throw AssertionError() + if (!(element11 in 1 .. 3) != !range0.contains(element11)) throw AssertionError() + if (!(element11 !in 1 .. 3) != range0.contains(element11)) throw AssertionError() +} + +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() + // no local optimizations + if (element12 in 1 .. 3 != range0.contains(element12)) throw AssertionError() + if (element12 !in 1 .. 3 != !range0.contains(element12)) throw AssertionError() + if (!(element12 in 1 .. 3) != !range0.contains(element12)) throw AssertionError() + if (!(element12 !in 1 .. 3) != range0.contains(element12)) throw AssertionError() +} + +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() + // no local optimizations + if (element13 in 1 .. 3 != range0.contains(element13)) throw AssertionError() + if (element13 !in 1 .. 3 != !range0.contains(element13)) throw AssertionError() + if (!(element13 in 1 .. 3) != !range0.contains(element13)) throw AssertionError() + if (!(element13 !in 1 .. 3) != range0.contains(element13)) throw AssertionError() +} + +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() + // no local optimizations + if (element14 in 1 .. 3 != range0.contains(element14)) throw AssertionError() + if (element14 !in 1 .. 3 != !range0.contains(element14)) throw AssertionError() + if (!(element14 in 1 .. 3) != !range0.contains(element14)) throw AssertionError() + if (!(element14 !in 1 .. 3) != range0.contains(element14)) throw AssertionError() +} + +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() + // no local optimizations + if (element15 in 1 .. 3 != range0.contains(element15)) throw AssertionError() + if (element15 !in 1 .. 3 != !range0.contains(element15)) throw AssertionError() + if (!(element15 in 1 .. 3) != !range0.contains(element15)) throw AssertionError() + if (!(element15 !in 1 .. 3) != range0.contains(element15)) throw AssertionError() +} + +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() + // no local optimizations + if (element16 in 1 .. 3 != range0.contains(element16)) throw AssertionError() + if (element16 !in 1 .. 3 != !range0.contains(element16)) throw AssertionError() + if (!(element16 in 1 .. 3) != !range0.contains(element16)) throw AssertionError() + if (!(element16 !in 1 .. 3) != range0.contains(element16)) throw AssertionError() +} + +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() + // no local optimizations + if (element17 in 1 .. 3 != range0.contains(element17)) throw AssertionError() + if (element17 !in 1 .. 3 != !range0.contains(element17)) throw AssertionError() + if (!(element17 in 1 .. 3) != !range0.contains(element17)) throw AssertionError() + if (!(element17 !in 1 .. 3) != range0.contains(element17)) throw AssertionError() +} + +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() + // no local optimizations + if (element18 in 1 .. 3 != range0.contains(element18)) throw AssertionError() + if (element18 !in 1 .. 3 != !range0.contains(element18)) throw AssertionError() + if (!(element18 in 1 .. 3) != !range0.contains(element18)) throw AssertionError() + if (!(element18 !in 1 .. 3) != range0.contains(element18)) throw AssertionError() +} + +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() + // no local optimizations + if (element19 in 1 .. 3 != range0.contains(element19)) throw AssertionError() + if (element19 !in 1 .. 3 != !range0.contains(element19)) throw AssertionError() + if (!(element19 in 1 .. 3) != !range0.contains(element19)) throw AssertionError() + if (!(element19 !in 1 .. 3) != range0.contains(element19)) throw AssertionError() +} + +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() + // no local optimizations + if (element20 in 1 .. 3 != range0.contains(element20)) throw AssertionError() + if (element20 !in 1 .. 3 != !range0.contains(element20)) throw AssertionError() + if (!(element20 in 1 .. 3) != !range0.contains(element20)) throw AssertionError() + if (!(element20 !in 1 .. 3) != range0.contains(element20)) throw AssertionError() +} + +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() + // no local optimizations + if (element21 in 1 .. 3 != range0.contains(element21)) throw AssertionError() + if (element21 !in 1 .. 3 != !range0.contains(element21)) throw AssertionError() + if (!(element21 in 1 .. 3) != !range0.contains(element21)) throw AssertionError() + if (!(element21 !in 1 .. 3) != range0.contains(element21)) throw AssertionError() +} + +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() + // no local optimizations + if (element22 in 1 .. 3 != range0.contains(element22)) throw AssertionError() + if (element22 !in 1 .. 3 != !range0.contains(element22)) throw AssertionError() + if (!(element22 in 1 .. 3) != !range0.contains(element22)) throw AssertionError() + if (!(element22 !in 1 .. 3) != range0.contains(element22)) throw AssertionError() +} + +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() +} + +fun testR1xE0() { + // 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() + // no local optimizations + if (element0 in 3 .. 1 != range1.contains(element0)) throw AssertionError() + if (element0 !in 3 .. 1 != !range1.contains(element0)) throw AssertionError() + if (!(element0 in 3 .. 1) != !range1.contains(element0)) throw AssertionError() + if (!(element0 !in 3 .. 1) != range1.contains(element0)) throw AssertionError() +} + +fun testR1xE1() { + // 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() + // no local optimizations + if (element1 in 3 .. 1 != range1.contains(element1)) throw AssertionError() + if (element1 !in 3 .. 1 != !range1.contains(element1)) throw AssertionError() + if (!(element1 in 3 .. 1) != !range1.contains(element1)) throw AssertionError() + if (!(element1 !in 3 .. 1) != range1.contains(element1)) throw AssertionError() +} + +fun testR1xE2() { + // 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() + // no local optimizations + if (element2 in 3 .. 1 != range1.contains(element2)) throw AssertionError() + if (element2 !in 3 .. 1 != !range1.contains(element2)) throw AssertionError() + if (!(element2 in 3 .. 1) != !range1.contains(element2)) throw AssertionError() + if (!(element2 !in 3 .. 1) != range1.contains(element2)) throw AssertionError() +} + +fun testR1xE3() { + // 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() + // no local optimizations + if (element3 in 3 .. 1 != range1.contains(element3)) throw AssertionError() + if (element3 !in 3 .. 1 != !range1.contains(element3)) throw AssertionError() + if (!(element3 in 3 .. 1) != !range1.contains(element3)) throw AssertionError() + if (!(element3 !in 3 .. 1) != range1.contains(element3)) throw AssertionError() +} + +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() + // no local optimizations + if (element4 in 3 .. 1 != range1.contains(element4)) throw AssertionError() + if (element4 !in 3 .. 1 != !range1.contains(element4)) throw AssertionError() + if (!(element4 in 3 .. 1) != !range1.contains(element4)) throw AssertionError() + if (!(element4 !in 3 .. 1) != range1.contains(element4)) throw AssertionError() +} + +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() + // no local optimizations + if (element5 in 3 .. 1 != range1.contains(element5)) throw AssertionError() + if (element5 !in 3 .. 1 != !range1.contains(element5)) throw AssertionError() + if (!(element5 in 3 .. 1) != !range1.contains(element5)) throw AssertionError() + if (!(element5 !in 3 .. 1) != range1.contains(element5)) throw AssertionError() +} + +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() + // no local optimizations + if (element6 in 3 .. 1 != range1.contains(element6)) throw AssertionError() + if (element6 !in 3 .. 1 != !range1.contains(element6)) throw AssertionError() + if (!(element6 in 3 .. 1) != !range1.contains(element6)) throw AssertionError() + if (!(element6 !in 3 .. 1) != range1.contains(element6)) throw AssertionError() +} + +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() + // no local optimizations + if (element7 in 3 .. 1 != range1.contains(element7)) throw AssertionError() + if (element7 !in 3 .. 1 != !range1.contains(element7)) throw AssertionError() + if (!(element7 in 3 .. 1) != !range1.contains(element7)) throw AssertionError() + if (!(element7 !in 3 .. 1) != range1.contains(element7)) throw AssertionError() +} + +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() + // no local optimizations + if (element8 in 3 .. 1 != range1.contains(element8)) throw AssertionError() + if (element8 !in 3 .. 1 != !range1.contains(element8)) throw AssertionError() + if (!(element8 in 3 .. 1) != !range1.contains(element8)) throw AssertionError() + if (!(element8 !in 3 .. 1) != range1.contains(element8)) throw AssertionError() +} + +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() + // no local optimizations + if (element9 in 3 .. 1 != range1.contains(element9)) throw AssertionError() + if (element9 !in 3 .. 1 != !range1.contains(element9)) throw AssertionError() + if (!(element9 in 3 .. 1) != !range1.contains(element9)) throw AssertionError() + if (!(element9 !in 3 .. 1) != range1.contains(element9)) throw AssertionError() +} + +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() + // no local optimizations + if (element10 in 3 .. 1 != range1.contains(element10)) throw AssertionError() + if (element10 !in 3 .. 1 != !range1.contains(element10)) throw AssertionError() + if (!(element10 in 3 .. 1) != !range1.contains(element10)) throw AssertionError() + if (!(element10 !in 3 .. 1) != range1.contains(element10)) throw AssertionError() +} + +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() + // no local optimizations + if (element11 in 3 .. 1 != range1.contains(element11)) throw AssertionError() + if (element11 !in 3 .. 1 != !range1.contains(element11)) throw AssertionError() + if (!(element11 in 3 .. 1) != !range1.contains(element11)) throw AssertionError() + if (!(element11 !in 3 .. 1) != range1.contains(element11)) throw AssertionError() +} + +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() + // no local optimizations + if (element12 in 3 .. 1 != range1.contains(element12)) throw AssertionError() + if (element12 !in 3 .. 1 != !range1.contains(element12)) throw AssertionError() + if (!(element12 in 3 .. 1) != !range1.contains(element12)) throw AssertionError() + if (!(element12 !in 3 .. 1) != range1.contains(element12)) throw AssertionError() +} + +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() + // no local optimizations + if (element13 in 3 .. 1 != range1.contains(element13)) throw AssertionError() + if (element13 !in 3 .. 1 != !range1.contains(element13)) throw AssertionError() + if (!(element13 in 3 .. 1) != !range1.contains(element13)) throw AssertionError() + if (!(element13 !in 3 .. 1) != range1.contains(element13)) throw AssertionError() +} + +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() + // no local optimizations + if (element14 in 3 .. 1 != range1.contains(element14)) throw AssertionError() + if (element14 !in 3 .. 1 != !range1.contains(element14)) throw AssertionError() + if (!(element14 in 3 .. 1) != !range1.contains(element14)) throw AssertionError() + if (!(element14 !in 3 .. 1) != range1.contains(element14)) throw AssertionError() +} + +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() + // no local optimizations + if (element15 in 3 .. 1 != range1.contains(element15)) throw AssertionError() + if (element15 !in 3 .. 1 != !range1.contains(element15)) throw AssertionError() + if (!(element15 in 3 .. 1) != !range1.contains(element15)) throw AssertionError() + if (!(element15 !in 3 .. 1) != range1.contains(element15)) throw AssertionError() +} + +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() + // no local optimizations + if (element16 in 3 .. 1 != range1.contains(element16)) throw AssertionError() + if (element16 !in 3 .. 1 != !range1.contains(element16)) throw AssertionError() + if (!(element16 in 3 .. 1) != !range1.contains(element16)) throw AssertionError() + if (!(element16 !in 3 .. 1) != range1.contains(element16)) throw AssertionError() +} + +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() + // no local optimizations + if (element17 in 3 .. 1 != range1.contains(element17)) throw AssertionError() + if (element17 !in 3 .. 1 != !range1.contains(element17)) throw AssertionError() + if (!(element17 in 3 .. 1) != !range1.contains(element17)) throw AssertionError() + if (!(element17 !in 3 .. 1) != range1.contains(element17)) throw AssertionError() +} + +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() + // no local optimizations + if (element18 in 3 .. 1 != range1.contains(element18)) throw AssertionError() + if (element18 !in 3 .. 1 != !range1.contains(element18)) throw AssertionError() + if (!(element18 in 3 .. 1) != !range1.contains(element18)) throw AssertionError() + if (!(element18 !in 3 .. 1) != range1.contains(element18)) throw AssertionError() +} + +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() + // no local optimizations + if (element19 in 3 .. 1 != range1.contains(element19)) throw AssertionError() + if (element19 !in 3 .. 1 != !range1.contains(element19)) throw AssertionError() + if (!(element19 in 3 .. 1) != !range1.contains(element19)) throw AssertionError() + if (!(element19 !in 3 .. 1) != range1.contains(element19)) throw AssertionError() +} + +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() + // no local optimizations + if (element20 in 3 .. 1 != range1.contains(element20)) throw AssertionError() + if (element20 !in 3 .. 1 != !range1.contains(element20)) throw AssertionError() + if (!(element20 in 3 .. 1) != !range1.contains(element20)) throw AssertionError() + if (!(element20 !in 3 .. 1) != range1.contains(element20)) throw AssertionError() +} + +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() + // no local optimizations + if (element21 in 3 .. 1 != range1.contains(element21)) throw AssertionError() + if (element21 !in 3 .. 1 != !range1.contains(element21)) throw AssertionError() + if (!(element21 in 3 .. 1) != !range1.contains(element21)) throw AssertionError() + if (!(element21 !in 3 .. 1) != range1.contains(element21)) throw AssertionError() +} + +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() + // no local optimizations + if (element22 in 3 .. 1 != range1.contains(element22)) throw AssertionError() + if (element22 !in 3 .. 1 != !range1.contains(element22)) throw AssertionError() + if (!(element22 in 3 .. 1) != !range1.contains(element22)) throw AssertionError() + if (!(element22 !in 3 .. 1) != range1.contains(element22)) throw AssertionError() +} + +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() + // no local optimizations + if (element23 in 3 .. 1 != range1.contains(element23)) throw AssertionError() + if (element23 !in 3 .. 1 != !range1.contains(element23)) throw AssertionError() + if (!(element23 in 3 .. 1) != !range1.contains(element23)) throw AssertionError() + 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 new file mode 100644 index 00000000000..036c8f06b55 --- /dev/null +++ b/compiler/testData/codegen/box/ranges/contains/generated/intUntil.kt @@ -0,0 +1,1058 @@ +// Auto-generated by GenerateInRangeExpressionTestData. Do not edit! +// WITH_RUNTIME + + + +val range0 = 1 until 3 +val range1 = 3 until 1 + +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() + +fun box(): String { + testR0xE0() + testR0xE1() + testR0xE2() + testR0xE3() + testR0xE4() + testR0xE5() + testR0xE6() + testR0xE7() + testR0xE8() + 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() + testR1xE3() + testR1xE4() + testR1xE5() + testR1xE6() + testR1xE7() + testR1xE8() + 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 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 (element0 in 1 until 3 != range0.contains(element0)) throw AssertionError() + if (element0 !in 1 until 3 != !range0.contains(element0)) throw AssertionError() + if (!(element0 in 1 until 3) != !range0.contains(element0)) throw AssertionError() + if (!(element0 !in 1 until 3) != range0.contains(element0)) throw AssertionError() +} + +fun testR0xE1() { + // 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() + // no local optimizations + if (element1 in 1 until 3 != range0.contains(element1)) throw AssertionError() + if (element1 !in 1 until 3 != !range0.contains(element1)) throw AssertionError() + if (!(element1 in 1 until 3) != !range0.contains(element1)) throw AssertionError() + if (!(element1 !in 1 until 3) != range0.contains(element1)) throw AssertionError() +} + +fun testR0xE2() { + // 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() + // no local optimizations + if (element2 in 1 until 3 != range0.contains(element2)) throw AssertionError() + if (element2 !in 1 until 3 != !range0.contains(element2)) throw AssertionError() + if (!(element2 in 1 until 3) != !range0.contains(element2)) throw AssertionError() + if (!(element2 !in 1 until 3) != range0.contains(element2)) throw AssertionError() +} + +fun testR0xE3() { + // 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() + // no local optimizations + if (element3 in 1 until 3 != range0.contains(element3)) throw AssertionError() + if (element3 !in 1 until 3 != !range0.contains(element3)) throw AssertionError() + if (!(element3 in 1 until 3) != !range0.contains(element3)) throw AssertionError() + if (!(element3 !in 1 until 3) != range0.contains(element3)) throw AssertionError() +} + +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() + // 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() + if (!(element4 in 1 until 3) != !range0.contains(element4)) throw AssertionError() + if (!(element4 !in 1 until 3) != range0.contains(element4)) throw AssertionError() +} + +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() + // 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() + if (!(element5 in 1 until 3) != !range0.contains(element5)) throw AssertionError() + if (!(element5 !in 1 until 3) != range0.contains(element5)) throw AssertionError() +} + +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() + // 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() + if (!(element6 in 1 until 3) != !range0.contains(element6)) throw AssertionError() + if (!(element6 !in 1 until 3) != range0.contains(element6)) throw AssertionError() +} + +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() + // 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() + if (!(element7 in 1 until 3) != !range0.contains(element7)) throw AssertionError() + if (!(element7 !in 1 until 3) != range0.contains(element7)) throw AssertionError() +} + +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() + // 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() + if (!(element8 in 1 until 3) != !range0.contains(element8)) throw AssertionError() + if (!(element8 !in 1 until 3) != range0.contains(element8)) throw AssertionError() +} + +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() + // 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() + if (!(element9 in 1 until 3) != !range0.contains(element9)) throw AssertionError() + if (!(element9 !in 1 until 3) != range0.contains(element9)) throw AssertionError() +} + +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() + // 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() + if (!(element10 in 1 until 3) != !range0.contains(element10)) throw AssertionError() + if (!(element10 !in 1 until 3) != range0.contains(element10)) throw AssertionError() +} + +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() + // 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() + if (!(element11 in 1 until 3) != !range0.contains(element11)) throw AssertionError() + if (!(element11 !in 1 until 3) != range0.contains(element11)) throw AssertionError() +} + +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() + // 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() + if (!(element12 in 1 until 3) != !range0.contains(element12)) throw AssertionError() + if (!(element12 !in 1 until 3) != range0.contains(element12)) throw AssertionError() +} + +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() + // 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() + if (!(element13 in 1 until 3) != !range0.contains(element13)) throw AssertionError() + if (!(element13 !in 1 until 3) != range0.contains(element13)) throw AssertionError() +} + +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() + // 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() + if (!(element14 in 1 until 3) != !range0.contains(element14)) throw AssertionError() + if (!(element14 !in 1 until 3) != range0.contains(element14)) throw AssertionError() +} + +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() + // 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() + if (!(element15 in 1 until 3) != !range0.contains(element15)) throw AssertionError() + if (!(element15 !in 1 until 3) != range0.contains(element15)) throw AssertionError() +} + +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() + // 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() + if (!(element16 in 1 until 3) != !range0.contains(element16)) throw AssertionError() + if (!(element16 !in 1 until 3) != range0.contains(element16)) throw AssertionError() +} + +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() + // 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() + if (!(element17 in 1 until 3) != !range0.contains(element17)) throw AssertionError() + if (!(element17 !in 1 until 3) != range0.contains(element17)) throw AssertionError() +} + +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() + // 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() + if (!(element18 in 1 until 3) != !range0.contains(element18)) throw AssertionError() + if (!(element18 !in 1 until 3) != range0.contains(element18)) throw AssertionError() +} + +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() + // 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() + if (!(element19 in 1 until 3) != !range0.contains(element19)) throw AssertionError() + if (!(element19 !in 1 until 3) != range0.contains(element19)) throw AssertionError() +} + +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() + // 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() + if (!(element20 in 1 until 3) != !range0.contains(element20)) throw AssertionError() + if (!(element20 !in 1 until 3) != range0.contains(element20)) throw AssertionError() +} + +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() + // 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() + if (!(element21 in 1 until 3) != !range0.contains(element21)) throw AssertionError() + if (!(element21 !in 1 until 3) != range0.contains(element21)) throw AssertionError() +} + +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() + // 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() + if (!(element22 in 1 until 3) != !range0.contains(element22)) throw AssertionError() + if (!(element22 !in 1 until 3) != range0.contains(element22)) throw AssertionError() +} + +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() +} + +fun testR1xE0() { + // 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() + // no local optimizations + if (element0 in 3 until 1 != range1.contains(element0)) throw AssertionError() + if (element0 !in 3 until 1 != !range1.contains(element0)) throw AssertionError() + if (!(element0 in 3 until 1) != !range1.contains(element0)) throw AssertionError() + if (!(element0 !in 3 until 1) != range1.contains(element0)) throw AssertionError() +} + +fun testR1xE1() { + // 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() + // no local optimizations + if (element1 in 3 until 1 != range1.contains(element1)) throw AssertionError() + if (element1 !in 3 until 1 != !range1.contains(element1)) throw AssertionError() + if (!(element1 in 3 until 1) != !range1.contains(element1)) throw AssertionError() + if (!(element1 !in 3 until 1) != range1.contains(element1)) throw AssertionError() +} + +fun testR1xE2() { + // 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() + // no local optimizations + if (element2 in 3 until 1 != range1.contains(element2)) throw AssertionError() + if (element2 !in 3 until 1 != !range1.contains(element2)) throw AssertionError() + if (!(element2 in 3 until 1) != !range1.contains(element2)) throw AssertionError() + if (!(element2 !in 3 until 1) != range1.contains(element2)) throw AssertionError() +} + +fun testR1xE3() { + // 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() + // no local optimizations + if (element3 in 3 until 1 != range1.contains(element3)) throw AssertionError() + if (element3 !in 3 until 1 != !range1.contains(element3)) throw AssertionError() + if (!(element3 in 3 until 1) != !range1.contains(element3)) throw AssertionError() + if (!(element3 !in 3 until 1) != range1.contains(element3)) throw AssertionError() +} + +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() + // 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() + if (!(element4 in 3 until 1) != !range1.contains(element4)) throw AssertionError() + if (!(element4 !in 3 until 1) != range1.contains(element4)) throw AssertionError() +} + +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() + // 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() + if (!(element5 in 3 until 1) != !range1.contains(element5)) throw AssertionError() + if (!(element5 !in 3 until 1) != range1.contains(element5)) throw AssertionError() +} + +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() + // 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() + if (!(element6 in 3 until 1) != !range1.contains(element6)) throw AssertionError() + if (!(element6 !in 3 until 1) != range1.contains(element6)) throw AssertionError() +} + +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() + // 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() + if (!(element7 in 3 until 1) != !range1.contains(element7)) throw AssertionError() + if (!(element7 !in 3 until 1) != range1.contains(element7)) throw AssertionError() +} + +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() + // 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() + if (!(element8 in 3 until 1) != !range1.contains(element8)) throw AssertionError() + if (!(element8 !in 3 until 1) != range1.contains(element8)) throw AssertionError() +} + +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() + // 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() + if (!(element9 in 3 until 1) != !range1.contains(element9)) throw AssertionError() + if (!(element9 !in 3 until 1) != range1.contains(element9)) throw AssertionError() +} + +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() + // 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() + if (!(element10 in 3 until 1) != !range1.contains(element10)) throw AssertionError() + if (!(element10 !in 3 until 1) != range1.contains(element10)) throw AssertionError() +} + +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() + // 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() + if (!(element11 in 3 until 1) != !range1.contains(element11)) throw AssertionError() + if (!(element11 !in 3 until 1) != range1.contains(element11)) throw AssertionError() +} + +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() + // 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() + if (!(element12 in 3 until 1) != !range1.contains(element12)) throw AssertionError() + if (!(element12 !in 3 until 1) != range1.contains(element12)) throw AssertionError() +} + +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() + // 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() + if (!(element13 in 3 until 1) != !range1.contains(element13)) throw AssertionError() + if (!(element13 !in 3 until 1) != range1.contains(element13)) throw AssertionError() +} + +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() + // 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() + if (!(element14 in 3 until 1) != !range1.contains(element14)) throw AssertionError() + if (!(element14 !in 3 until 1) != range1.contains(element14)) throw AssertionError() +} + +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() + // 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() + if (!(element15 in 3 until 1) != !range1.contains(element15)) throw AssertionError() + if (!(element15 !in 3 until 1) != range1.contains(element15)) throw AssertionError() +} + +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() + // 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() + if (!(element16 in 3 until 1) != !range1.contains(element16)) throw AssertionError() + if (!(element16 !in 3 until 1) != range1.contains(element16)) throw AssertionError() +} + +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() + // 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() + if (!(element17 in 3 until 1) != !range1.contains(element17)) throw AssertionError() + if (!(element17 !in 3 until 1) != range1.contains(element17)) throw AssertionError() +} + +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() + // 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() + if (!(element18 in 3 until 1) != !range1.contains(element18)) throw AssertionError() + if (!(element18 !in 3 until 1) != range1.contains(element18)) throw AssertionError() +} + +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() + // 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() + if (!(element19 in 3 until 1) != !range1.contains(element19)) throw AssertionError() + if (!(element19 !in 3 until 1) != range1.contains(element19)) throw AssertionError() +} + +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() + // 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() + if (!(element20 in 3 until 1) != !range1.contains(element20)) throw AssertionError() + if (!(element20 !in 3 until 1) != range1.contains(element20)) throw AssertionError() +} + +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() + // 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() + if (!(element21 in 3 until 1) != !range1.contains(element21)) throw AssertionError() + if (!(element21 !in 3 until 1) != range1.contains(element21)) throw AssertionError() +} + +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() + // 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() + if (!(element22 in 3 until 1) != !range1.contains(element22)) throw AssertionError() + if (!(element22 !in 3 until 1) != range1.contains(element22)) throw AssertionError() +} + +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() + // 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() + if (!(element23 in 3 until 1) != !range1.contains(element23)) throw AssertionError() + 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/longDownTo.kt b/compiler/testData/codegen/box/ranges/contains/generated/longDownTo.kt new file mode 100644 index 00000000000..46a94bf7c1f --- /dev/null +++ b/compiler/testData/codegen/box/ranges/contains/generated/longDownTo.kt @@ -0,0 +1,43 @@ +// Auto-generated by GenerateInRangeExpressionTestData. Do not edit! +// WITH_RUNTIME + + + +val range0 = 3L downTo 1L +val range1 = 1L downTo 3L + +val element0 = 1L + +fun box(): String { + testR0xE0() + testR1xE0() + return "OK" +} + +fun testR0xE0() { + // with possible local optimizations + if (1L in 3L downTo 1L != range0.contains(1L)) throw AssertionError() + if (1L !in 3L downTo 1L != !range0.contains(1L)) throw AssertionError() + if (!(1L in 3L downTo 1L) != !range0.contains(1L)) throw AssertionError() + if (!(1L !in 3L downTo 1L) != range0.contains(1L)) throw AssertionError() + // no local optimizations + if (element0 in 3L downTo 1L != range0.contains(element0)) throw AssertionError() + if (element0 !in 3L downTo 1L != !range0.contains(element0)) throw AssertionError() + if (!(element0 in 3L downTo 1L) != !range0.contains(element0)) throw AssertionError() + if (!(element0 !in 3L downTo 1L) != range0.contains(element0)) throw AssertionError() +} + +fun testR1xE0() { + // with possible local optimizations + if (1L in 1L downTo 3L != range1.contains(1L)) throw AssertionError() + if (1L !in 1L downTo 3L != !range1.contains(1L)) throw AssertionError() + if (!(1L in 1L downTo 3L) != !range1.contains(1L)) throw AssertionError() + if (!(1L !in 1L downTo 3L) != range1.contains(1L)) throw AssertionError() + // no local optimizations + if (element0 in 1L downTo 3L != range1.contains(element0)) throw AssertionError() + if (element0 !in 1L downTo 3L != !range1.contains(element0)) throw AssertionError() + if (!(element0 in 1L downTo 3L) != !range1.contains(element0)) throw AssertionError() + if (!(element0 !in 1L downTo 3L) != range1.contains(element0)) throw AssertionError() +} + + diff --git a/compiler/testData/codegen/box/ranges/contains/generated/longRangeLiteral.kt b/compiler/testData/codegen/box/ranges/contains/generated/longRangeLiteral.kt new file mode 100644 index 00000000000..2d31e154f78 --- /dev/null +++ b/compiler/testData/codegen/box/ranges/contains/generated/longRangeLiteral.kt @@ -0,0 +1,1058 @@ +// Auto-generated by GenerateInRangeExpressionTestData. Do not edit! +// WITH_RUNTIME + + + +val range0 = 1L .. 3L +val range1 = 3L .. 1L + +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() + +fun box(): String { + testR0xE0() + testR0xE1() + testR0xE2() + testR0xE3() + testR0xE4() + testR0xE5() + testR0xE6() + testR0xE7() + testR0xE8() + 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() + testR1xE3() + testR1xE4() + testR1xE5() + testR1xE6() + testR1xE7() + testR1xE8() + 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 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 (element0 in 1L .. 3L != range0.contains(element0)) throw AssertionError() + if (element0 !in 1L .. 3L != !range0.contains(element0)) throw AssertionError() + if (!(element0 in 1L .. 3L) != !range0.contains(element0)) throw AssertionError() + if (!(element0 !in 1L .. 3L) != range0.contains(element0)) throw AssertionError() +} + +fun testR0xE1() { + // 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() + // no local optimizations + if (element1 in 1L .. 3L != range0.contains(element1)) throw AssertionError() + if (element1 !in 1L .. 3L != !range0.contains(element1)) throw AssertionError() + if (!(element1 in 1L .. 3L) != !range0.contains(element1)) throw AssertionError() + if (!(element1 !in 1L .. 3L) != range0.contains(element1)) throw AssertionError() +} + +fun testR0xE2() { + // 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() + // no local optimizations + if (element2 in 1L .. 3L != range0.contains(element2)) throw AssertionError() + if (element2 !in 1L .. 3L != !range0.contains(element2)) throw AssertionError() + if (!(element2 in 1L .. 3L) != !range0.contains(element2)) throw AssertionError() + if (!(element2 !in 1L .. 3L) != range0.contains(element2)) throw AssertionError() +} + +fun testR0xE3() { + // 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() + // no local optimizations + if (element3 in 1L .. 3L != range0.contains(element3)) throw AssertionError() + if (element3 !in 1L .. 3L != !range0.contains(element3)) throw AssertionError() + if (!(element3 in 1L .. 3L) != !range0.contains(element3)) throw AssertionError() + if (!(element3 !in 1L .. 3L) != range0.contains(element3)) throw AssertionError() +} + +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() + // no local optimizations + if (element4 in 1L .. 3L != range0.contains(element4)) throw AssertionError() + if (element4 !in 1L .. 3L != !range0.contains(element4)) throw AssertionError() + if (!(element4 in 1L .. 3L) != !range0.contains(element4)) throw AssertionError() + if (!(element4 !in 1L .. 3L) != range0.contains(element4)) throw AssertionError() +} + +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() + // no local optimizations + if (element5 in 1L .. 3L != range0.contains(element5)) throw AssertionError() + if (element5 !in 1L .. 3L != !range0.contains(element5)) throw AssertionError() + if (!(element5 in 1L .. 3L) != !range0.contains(element5)) throw AssertionError() + if (!(element5 !in 1L .. 3L) != range0.contains(element5)) throw AssertionError() +} + +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() + // no local optimizations + if (element6 in 1L .. 3L != range0.contains(element6)) throw AssertionError() + if (element6 !in 1L .. 3L != !range0.contains(element6)) throw AssertionError() + if (!(element6 in 1L .. 3L) != !range0.contains(element6)) throw AssertionError() + if (!(element6 !in 1L .. 3L) != range0.contains(element6)) throw AssertionError() +} + +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() + // no local optimizations + if (element7 in 1L .. 3L != range0.contains(element7)) throw AssertionError() + if (element7 !in 1L .. 3L != !range0.contains(element7)) throw AssertionError() + if (!(element7 in 1L .. 3L) != !range0.contains(element7)) throw AssertionError() + if (!(element7 !in 1L .. 3L) != range0.contains(element7)) throw AssertionError() +} + +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() + // no local optimizations + if (element8 in 1L .. 3L != range0.contains(element8)) throw AssertionError() + if (element8 !in 1L .. 3L != !range0.contains(element8)) throw AssertionError() + if (!(element8 in 1L .. 3L) != !range0.contains(element8)) throw AssertionError() + if (!(element8 !in 1L .. 3L) != range0.contains(element8)) throw AssertionError() +} + +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() + // no local optimizations + if (element9 in 1L .. 3L != range0.contains(element9)) throw AssertionError() + if (element9 !in 1L .. 3L != !range0.contains(element9)) throw AssertionError() + if (!(element9 in 1L .. 3L) != !range0.contains(element9)) throw AssertionError() + if (!(element9 !in 1L .. 3L) != range0.contains(element9)) throw AssertionError() +} + +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() + // no local optimizations + if (element10 in 1L .. 3L != range0.contains(element10)) throw AssertionError() + if (element10 !in 1L .. 3L != !range0.contains(element10)) throw AssertionError() + if (!(element10 in 1L .. 3L) != !range0.contains(element10)) throw AssertionError() + if (!(element10 !in 1L .. 3L) != range0.contains(element10)) throw AssertionError() +} + +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() + // no local optimizations + if (element11 in 1L .. 3L != range0.contains(element11)) throw AssertionError() + if (element11 !in 1L .. 3L != !range0.contains(element11)) throw AssertionError() + if (!(element11 in 1L .. 3L) != !range0.contains(element11)) throw AssertionError() + if (!(element11 !in 1L .. 3L) != range0.contains(element11)) throw AssertionError() +} + +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() + // no local optimizations + if (element12 in 1L .. 3L != range0.contains(element12)) throw AssertionError() + if (element12 !in 1L .. 3L != !range0.contains(element12)) throw AssertionError() + if (!(element12 in 1L .. 3L) != !range0.contains(element12)) throw AssertionError() + if (!(element12 !in 1L .. 3L) != range0.contains(element12)) throw AssertionError() +} + +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() + // no local optimizations + if (element13 in 1L .. 3L != range0.contains(element13)) throw AssertionError() + if (element13 !in 1L .. 3L != !range0.contains(element13)) throw AssertionError() + if (!(element13 in 1L .. 3L) != !range0.contains(element13)) throw AssertionError() + if (!(element13 !in 1L .. 3L) != range0.contains(element13)) throw AssertionError() +} + +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() + // no local optimizations + if (element14 in 1L .. 3L != range0.contains(element14)) throw AssertionError() + if (element14 !in 1L .. 3L != !range0.contains(element14)) throw AssertionError() + if (!(element14 in 1L .. 3L) != !range0.contains(element14)) throw AssertionError() + if (!(element14 !in 1L .. 3L) != range0.contains(element14)) throw AssertionError() +} + +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() + // no local optimizations + if (element15 in 1L .. 3L != range0.contains(element15)) throw AssertionError() + if (element15 !in 1L .. 3L != !range0.contains(element15)) throw AssertionError() + if (!(element15 in 1L .. 3L) != !range0.contains(element15)) throw AssertionError() + if (!(element15 !in 1L .. 3L) != range0.contains(element15)) throw AssertionError() +} + +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() + // no local optimizations + if (element16 in 1L .. 3L != range0.contains(element16)) throw AssertionError() + if (element16 !in 1L .. 3L != !range0.contains(element16)) throw AssertionError() + if (!(element16 in 1L .. 3L) != !range0.contains(element16)) throw AssertionError() + if (!(element16 !in 1L .. 3L) != range0.contains(element16)) throw AssertionError() +} + +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() + // no local optimizations + if (element17 in 1L .. 3L != range0.contains(element17)) throw AssertionError() + if (element17 !in 1L .. 3L != !range0.contains(element17)) throw AssertionError() + if (!(element17 in 1L .. 3L) != !range0.contains(element17)) throw AssertionError() + if (!(element17 !in 1L .. 3L) != range0.contains(element17)) throw AssertionError() +} + +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() + // no local optimizations + if (element18 in 1L .. 3L != range0.contains(element18)) throw AssertionError() + if (element18 !in 1L .. 3L != !range0.contains(element18)) throw AssertionError() + if (!(element18 in 1L .. 3L) != !range0.contains(element18)) throw AssertionError() + if (!(element18 !in 1L .. 3L) != range0.contains(element18)) throw AssertionError() +} + +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() + // no local optimizations + if (element19 in 1L .. 3L != range0.contains(element19)) throw AssertionError() + if (element19 !in 1L .. 3L != !range0.contains(element19)) throw AssertionError() + if (!(element19 in 1L .. 3L) != !range0.contains(element19)) throw AssertionError() + if (!(element19 !in 1L .. 3L) != range0.contains(element19)) throw AssertionError() +} + +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() + // no local optimizations + if (element20 in 1L .. 3L != range0.contains(element20)) throw AssertionError() + if (element20 !in 1L .. 3L != !range0.contains(element20)) throw AssertionError() + if (!(element20 in 1L .. 3L) != !range0.contains(element20)) throw AssertionError() + if (!(element20 !in 1L .. 3L) != range0.contains(element20)) throw AssertionError() +} + +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() + // no local optimizations + if (element21 in 1L .. 3L != range0.contains(element21)) throw AssertionError() + if (element21 !in 1L .. 3L != !range0.contains(element21)) throw AssertionError() + if (!(element21 in 1L .. 3L) != !range0.contains(element21)) throw AssertionError() + if (!(element21 !in 1L .. 3L) != range0.contains(element21)) throw AssertionError() +} + +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() + // no local optimizations + if (element22 in 1L .. 3L != range0.contains(element22)) throw AssertionError() + if (element22 !in 1L .. 3L != !range0.contains(element22)) throw AssertionError() + if (!(element22 in 1L .. 3L) != !range0.contains(element22)) throw AssertionError() + if (!(element22 !in 1L .. 3L) != range0.contains(element22)) throw AssertionError() +} + +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() +} + +fun testR1xE0() { + // 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() + // no local optimizations + if (element0 in 3L .. 1L != range1.contains(element0)) throw AssertionError() + if (element0 !in 3L .. 1L != !range1.contains(element0)) throw AssertionError() + if (!(element0 in 3L .. 1L) != !range1.contains(element0)) throw AssertionError() + if (!(element0 !in 3L .. 1L) != range1.contains(element0)) throw AssertionError() +} + +fun testR1xE1() { + // 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() + // no local optimizations + if (element1 in 3L .. 1L != range1.contains(element1)) throw AssertionError() + if (element1 !in 3L .. 1L != !range1.contains(element1)) throw AssertionError() + if (!(element1 in 3L .. 1L) != !range1.contains(element1)) throw AssertionError() + if (!(element1 !in 3L .. 1L) != range1.contains(element1)) throw AssertionError() +} + +fun testR1xE2() { + // 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() + // no local optimizations + if (element2 in 3L .. 1L != range1.contains(element2)) throw AssertionError() + if (element2 !in 3L .. 1L != !range1.contains(element2)) throw AssertionError() + if (!(element2 in 3L .. 1L) != !range1.contains(element2)) throw AssertionError() + if (!(element2 !in 3L .. 1L) != range1.contains(element2)) throw AssertionError() +} + +fun testR1xE3() { + // 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() + // no local optimizations + if (element3 in 3L .. 1L != range1.contains(element3)) throw AssertionError() + if (element3 !in 3L .. 1L != !range1.contains(element3)) throw AssertionError() + if (!(element3 in 3L .. 1L) != !range1.contains(element3)) throw AssertionError() + if (!(element3 !in 3L .. 1L) != range1.contains(element3)) throw AssertionError() +} + +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() + // no local optimizations + if (element4 in 3L .. 1L != range1.contains(element4)) throw AssertionError() + if (element4 !in 3L .. 1L != !range1.contains(element4)) throw AssertionError() + if (!(element4 in 3L .. 1L) != !range1.contains(element4)) throw AssertionError() + if (!(element4 !in 3L .. 1L) != range1.contains(element4)) throw AssertionError() +} + +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() + // no local optimizations + if (element5 in 3L .. 1L != range1.contains(element5)) throw AssertionError() + if (element5 !in 3L .. 1L != !range1.contains(element5)) throw AssertionError() + if (!(element5 in 3L .. 1L) != !range1.contains(element5)) throw AssertionError() + if (!(element5 !in 3L .. 1L) != range1.contains(element5)) throw AssertionError() +} + +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() + // no local optimizations + if (element6 in 3L .. 1L != range1.contains(element6)) throw AssertionError() + if (element6 !in 3L .. 1L != !range1.contains(element6)) throw AssertionError() + if (!(element6 in 3L .. 1L) != !range1.contains(element6)) throw AssertionError() + if (!(element6 !in 3L .. 1L) != range1.contains(element6)) throw AssertionError() +} + +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() + // no local optimizations + if (element7 in 3L .. 1L != range1.contains(element7)) throw AssertionError() + if (element7 !in 3L .. 1L != !range1.contains(element7)) throw AssertionError() + if (!(element7 in 3L .. 1L) != !range1.contains(element7)) throw AssertionError() + if (!(element7 !in 3L .. 1L) != range1.contains(element7)) throw AssertionError() +} + +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() + // no local optimizations + if (element8 in 3L .. 1L != range1.contains(element8)) throw AssertionError() + if (element8 !in 3L .. 1L != !range1.contains(element8)) throw AssertionError() + if (!(element8 in 3L .. 1L) != !range1.contains(element8)) throw AssertionError() + if (!(element8 !in 3L .. 1L) != range1.contains(element8)) throw AssertionError() +} + +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() + // no local optimizations + if (element9 in 3L .. 1L != range1.contains(element9)) throw AssertionError() + if (element9 !in 3L .. 1L != !range1.contains(element9)) throw AssertionError() + if (!(element9 in 3L .. 1L) != !range1.contains(element9)) throw AssertionError() + if (!(element9 !in 3L .. 1L) != range1.contains(element9)) throw AssertionError() +} + +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() + // no local optimizations + if (element10 in 3L .. 1L != range1.contains(element10)) throw AssertionError() + if (element10 !in 3L .. 1L != !range1.contains(element10)) throw AssertionError() + if (!(element10 in 3L .. 1L) != !range1.contains(element10)) throw AssertionError() + if (!(element10 !in 3L .. 1L) != range1.contains(element10)) throw AssertionError() +} + +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() + // no local optimizations + if (element11 in 3L .. 1L != range1.contains(element11)) throw AssertionError() + if (element11 !in 3L .. 1L != !range1.contains(element11)) throw AssertionError() + if (!(element11 in 3L .. 1L) != !range1.contains(element11)) throw AssertionError() + if (!(element11 !in 3L .. 1L) != range1.contains(element11)) throw AssertionError() +} + +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() + // no local optimizations + if (element12 in 3L .. 1L != range1.contains(element12)) throw AssertionError() + if (element12 !in 3L .. 1L != !range1.contains(element12)) throw AssertionError() + if (!(element12 in 3L .. 1L) != !range1.contains(element12)) throw AssertionError() + if (!(element12 !in 3L .. 1L) != range1.contains(element12)) throw AssertionError() +} + +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() + // no local optimizations + if (element13 in 3L .. 1L != range1.contains(element13)) throw AssertionError() + if (element13 !in 3L .. 1L != !range1.contains(element13)) throw AssertionError() + if (!(element13 in 3L .. 1L) != !range1.contains(element13)) throw AssertionError() + if (!(element13 !in 3L .. 1L) != range1.contains(element13)) throw AssertionError() +} + +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() + // no local optimizations + if (element14 in 3L .. 1L != range1.contains(element14)) throw AssertionError() + if (element14 !in 3L .. 1L != !range1.contains(element14)) throw AssertionError() + if (!(element14 in 3L .. 1L) != !range1.contains(element14)) throw AssertionError() + if (!(element14 !in 3L .. 1L) != range1.contains(element14)) throw AssertionError() +} + +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() + // no local optimizations + if (element15 in 3L .. 1L != range1.contains(element15)) throw AssertionError() + if (element15 !in 3L .. 1L != !range1.contains(element15)) throw AssertionError() + if (!(element15 in 3L .. 1L) != !range1.contains(element15)) throw AssertionError() + if (!(element15 !in 3L .. 1L) != range1.contains(element15)) throw AssertionError() +} + +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() + // no local optimizations + if (element16 in 3L .. 1L != range1.contains(element16)) throw AssertionError() + if (element16 !in 3L .. 1L != !range1.contains(element16)) throw AssertionError() + if (!(element16 in 3L .. 1L) != !range1.contains(element16)) throw AssertionError() + if (!(element16 !in 3L .. 1L) != range1.contains(element16)) throw AssertionError() +} + +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() + // no local optimizations + if (element17 in 3L .. 1L != range1.contains(element17)) throw AssertionError() + if (element17 !in 3L .. 1L != !range1.contains(element17)) throw AssertionError() + if (!(element17 in 3L .. 1L) != !range1.contains(element17)) throw AssertionError() + if (!(element17 !in 3L .. 1L) != range1.contains(element17)) throw AssertionError() +} + +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() + // no local optimizations + if (element18 in 3L .. 1L != range1.contains(element18)) throw AssertionError() + if (element18 !in 3L .. 1L != !range1.contains(element18)) throw AssertionError() + if (!(element18 in 3L .. 1L) != !range1.contains(element18)) throw AssertionError() + if (!(element18 !in 3L .. 1L) != range1.contains(element18)) throw AssertionError() +} + +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() + // no local optimizations + if (element19 in 3L .. 1L != range1.contains(element19)) throw AssertionError() + if (element19 !in 3L .. 1L != !range1.contains(element19)) throw AssertionError() + if (!(element19 in 3L .. 1L) != !range1.contains(element19)) throw AssertionError() + if (!(element19 !in 3L .. 1L) != range1.contains(element19)) throw AssertionError() +} + +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() + // no local optimizations + if (element20 in 3L .. 1L != range1.contains(element20)) throw AssertionError() + if (element20 !in 3L .. 1L != !range1.contains(element20)) throw AssertionError() + if (!(element20 in 3L .. 1L) != !range1.contains(element20)) throw AssertionError() + if (!(element20 !in 3L .. 1L) != range1.contains(element20)) throw AssertionError() +} + +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() + // no local optimizations + if (element21 in 3L .. 1L != range1.contains(element21)) throw AssertionError() + if (element21 !in 3L .. 1L != !range1.contains(element21)) throw AssertionError() + if (!(element21 in 3L .. 1L) != !range1.contains(element21)) throw AssertionError() + if (!(element21 !in 3L .. 1L) != range1.contains(element21)) throw AssertionError() +} + +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() + // no local optimizations + if (element22 in 3L .. 1L != range1.contains(element22)) throw AssertionError() + if (element22 !in 3L .. 1L != !range1.contains(element22)) throw AssertionError() + if (!(element22 in 3L .. 1L) != !range1.contains(element22)) throw AssertionError() + if (!(element22 !in 3L .. 1L) != range1.contains(element22)) throw AssertionError() +} + +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() + // no local optimizations + if (element23 in 3L .. 1L != range1.contains(element23)) throw AssertionError() + if (element23 !in 3L .. 1L != !range1.contains(element23)) throw AssertionError() + if (!(element23 in 3L .. 1L) != !range1.contains(element23)) throw AssertionError() + 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 new file mode 100644 index 00000000000..15efde78c8f --- /dev/null +++ b/compiler/testData/codegen/box/ranges/contains/generated/longUntil.kt @@ -0,0 +1,1058 @@ +// Auto-generated by GenerateInRangeExpressionTestData. Do not edit! +// WITH_RUNTIME + + + +val range0 = 1L until 3L +val range1 = 3L until 1L + +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() + +fun box(): String { + testR0xE0() + testR0xE1() + testR0xE2() + testR0xE3() + testR0xE4() + testR0xE5() + testR0xE6() + testR0xE7() + testR0xE8() + 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() + testR1xE3() + testR1xE4() + testR1xE5() + testR1xE6() + testR1xE7() + testR1xE8() + 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 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 (element0 in 1L until 3L != range0.contains(element0)) throw AssertionError() + if (element0 !in 1L until 3L != !range0.contains(element0)) throw AssertionError() + if (!(element0 in 1L until 3L) != !range0.contains(element0)) throw AssertionError() + if (!(element0 !in 1L until 3L) != range0.contains(element0)) throw AssertionError() +} + +fun testR0xE1() { + // 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() + // no local optimizations + if (element1 in 1L until 3L != range0.contains(element1)) throw AssertionError() + if (element1 !in 1L until 3L != !range0.contains(element1)) throw AssertionError() + if (!(element1 in 1L until 3L) != !range0.contains(element1)) throw AssertionError() + if (!(element1 !in 1L until 3L) != range0.contains(element1)) throw AssertionError() +} + +fun testR0xE2() { + // 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() + // no local optimizations + if (element2 in 1L until 3L != range0.contains(element2)) throw AssertionError() + if (element2 !in 1L until 3L != !range0.contains(element2)) throw AssertionError() + if (!(element2 in 1L until 3L) != !range0.contains(element2)) throw AssertionError() + if (!(element2 !in 1L until 3L) != range0.contains(element2)) throw AssertionError() +} + +fun testR0xE3() { + // 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() + // no local optimizations + if (element3 in 1L until 3L != range0.contains(element3)) throw AssertionError() + if (element3 !in 1L until 3L != !range0.contains(element3)) throw AssertionError() + if (!(element3 in 1L until 3L) != !range0.contains(element3)) throw AssertionError() + if (!(element3 !in 1L until 3L) != range0.contains(element3)) throw AssertionError() +} + +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() + // 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() + if (!(element4 in 1L until 3L) != !range0.contains(element4)) throw AssertionError() + if (!(element4 !in 1L until 3L) != range0.contains(element4)) throw AssertionError() +} + +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() + // 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() + if (!(element5 in 1L until 3L) != !range0.contains(element5)) throw AssertionError() + if (!(element5 !in 1L until 3L) != range0.contains(element5)) throw AssertionError() +} + +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() + // 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() + if (!(element6 in 1L until 3L) != !range0.contains(element6)) throw AssertionError() + if (!(element6 !in 1L until 3L) != range0.contains(element6)) throw AssertionError() +} + +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() + // 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() + if (!(element7 in 1L until 3L) != !range0.contains(element7)) throw AssertionError() + if (!(element7 !in 1L until 3L) != range0.contains(element7)) throw AssertionError() +} + +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() + // 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() + if (!(element8 in 1L until 3L) != !range0.contains(element8)) throw AssertionError() + if (!(element8 !in 1L until 3L) != range0.contains(element8)) throw AssertionError() +} + +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() + // 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() + if (!(element9 in 1L until 3L) != !range0.contains(element9)) throw AssertionError() + if (!(element9 !in 1L until 3L) != range0.contains(element9)) throw AssertionError() +} + +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() + // 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() + if (!(element10 in 1L until 3L) != !range0.contains(element10)) throw AssertionError() + if (!(element10 !in 1L until 3L) != range0.contains(element10)) throw AssertionError() +} + +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() + // 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() + if (!(element11 in 1L until 3L) != !range0.contains(element11)) throw AssertionError() + if (!(element11 !in 1L until 3L) != range0.contains(element11)) throw AssertionError() +} + +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() + // 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() + if (!(element12 in 1L until 3L) != !range0.contains(element12)) throw AssertionError() + if (!(element12 !in 1L until 3L) != range0.contains(element12)) throw AssertionError() +} + +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() + // 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() + if (!(element13 in 1L until 3L) != !range0.contains(element13)) throw AssertionError() + if (!(element13 !in 1L until 3L) != range0.contains(element13)) throw AssertionError() +} + +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() + // 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() + if (!(element14 in 1L until 3L) != !range0.contains(element14)) throw AssertionError() + if (!(element14 !in 1L until 3L) != range0.contains(element14)) throw AssertionError() +} + +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() + // 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() + if (!(element15 in 1L until 3L) != !range0.contains(element15)) throw AssertionError() + if (!(element15 !in 1L until 3L) != range0.contains(element15)) throw AssertionError() +} + +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() + // 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() + if (!(element16 in 1L until 3L) != !range0.contains(element16)) throw AssertionError() + if (!(element16 !in 1L until 3L) != range0.contains(element16)) throw AssertionError() +} + +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() + // 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() + if (!(element17 in 1L until 3L) != !range0.contains(element17)) throw AssertionError() + if (!(element17 !in 1L until 3L) != range0.contains(element17)) throw AssertionError() +} + +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() + // 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() + if (!(element18 in 1L until 3L) != !range0.contains(element18)) throw AssertionError() + if (!(element18 !in 1L until 3L) != range0.contains(element18)) throw AssertionError() +} + +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() + // 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() + if (!(element19 in 1L until 3L) != !range0.contains(element19)) throw AssertionError() + if (!(element19 !in 1L until 3L) != range0.contains(element19)) throw AssertionError() +} + +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() + // 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() + if (!(element20 in 1L until 3L) != !range0.contains(element20)) throw AssertionError() + if (!(element20 !in 1L until 3L) != range0.contains(element20)) throw AssertionError() +} + +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() + // 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() + if (!(element21 in 1L until 3L) != !range0.contains(element21)) throw AssertionError() + if (!(element21 !in 1L until 3L) != range0.contains(element21)) throw AssertionError() +} + +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() + // 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() + if (!(element22 in 1L until 3L) != !range0.contains(element22)) throw AssertionError() + if (!(element22 !in 1L until 3L) != range0.contains(element22)) throw AssertionError() +} + +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() +} + +fun testR1xE0() { + // 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() + // no local optimizations + if (element0 in 3L until 1L != range1.contains(element0)) throw AssertionError() + if (element0 !in 3L until 1L != !range1.contains(element0)) throw AssertionError() + if (!(element0 in 3L until 1L) != !range1.contains(element0)) throw AssertionError() + if (!(element0 !in 3L until 1L) != range1.contains(element0)) throw AssertionError() +} + +fun testR1xE1() { + // 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() + // no local optimizations + if (element1 in 3L until 1L != range1.contains(element1)) throw AssertionError() + if (element1 !in 3L until 1L != !range1.contains(element1)) throw AssertionError() + if (!(element1 in 3L until 1L) != !range1.contains(element1)) throw AssertionError() + if (!(element1 !in 3L until 1L) != range1.contains(element1)) throw AssertionError() +} + +fun testR1xE2() { + // 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() + // no local optimizations + if (element2 in 3L until 1L != range1.contains(element2)) throw AssertionError() + if (element2 !in 3L until 1L != !range1.contains(element2)) throw AssertionError() + if (!(element2 in 3L until 1L) != !range1.contains(element2)) throw AssertionError() + if (!(element2 !in 3L until 1L) != range1.contains(element2)) throw AssertionError() +} + +fun testR1xE3() { + // 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() + // no local optimizations + if (element3 in 3L until 1L != range1.contains(element3)) throw AssertionError() + if (element3 !in 3L until 1L != !range1.contains(element3)) throw AssertionError() + if (!(element3 in 3L until 1L) != !range1.contains(element3)) throw AssertionError() + if (!(element3 !in 3L until 1L) != range1.contains(element3)) throw AssertionError() +} + +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() + // 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() + if (!(element4 in 3L until 1L) != !range1.contains(element4)) throw AssertionError() + if (!(element4 !in 3L until 1L) != range1.contains(element4)) throw AssertionError() +} + +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() + // 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() + if (!(element5 in 3L until 1L) != !range1.contains(element5)) throw AssertionError() + if (!(element5 !in 3L until 1L) != range1.contains(element5)) throw AssertionError() +} + +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() + // 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() + if (!(element6 in 3L until 1L) != !range1.contains(element6)) throw AssertionError() + if (!(element6 !in 3L until 1L) != range1.contains(element6)) throw AssertionError() +} + +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() + // 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() + if (!(element7 in 3L until 1L) != !range1.contains(element7)) throw AssertionError() + if (!(element7 !in 3L until 1L) != range1.contains(element7)) throw AssertionError() +} + +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() + // 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() + if (!(element8 in 3L until 1L) != !range1.contains(element8)) throw AssertionError() + if (!(element8 !in 3L until 1L) != range1.contains(element8)) throw AssertionError() +} + +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() + // 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() + if (!(element9 in 3L until 1L) != !range1.contains(element9)) throw AssertionError() + if (!(element9 !in 3L until 1L) != range1.contains(element9)) throw AssertionError() +} + +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() + // 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() + if (!(element10 in 3L until 1L) != !range1.contains(element10)) throw AssertionError() + if (!(element10 !in 3L until 1L) != range1.contains(element10)) throw AssertionError() +} + +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() + // 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() + if (!(element11 in 3L until 1L) != !range1.contains(element11)) throw AssertionError() + if (!(element11 !in 3L until 1L) != range1.contains(element11)) throw AssertionError() +} + +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() + // 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() + if (!(element12 in 3L until 1L) != !range1.contains(element12)) throw AssertionError() + if (!(element12 !in 3L until 1L) != range1.contains(element12)) throw AssertionError() +} + +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() + // 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() + if (!(element13 in 3L until 1L) != !range1.contains(element13)) throw AssertionError() + if (!(element13 !in 3L until 1L) != range1.contains(element13)) throw AssertionError() +} + +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() + // 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() + if (!(element14 in 3L until 1L) != !range1.contains(element14)) throw AssertionError() + if (!(element14 !in 3L until 1L) != range1.contains(element14)) throw AssertionError() +} + +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() + // 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() + if (!(element15 in 3L until 1L) != !range1.contains(element15)) throw AssertionError() + if (!(element15 !in 3L until 1L) != range1.contains(element15)) throw AssertionError() +} + +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() + // 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() + if (!(element16 in 3L until 1L) != !range1.contains(element16)) throw AssertionError() + if (!(element16 !in 3L until 1L) != range1.contains(element16)) throw AssertionError() +} + +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() + // 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() + if (!(element17 in 3L until 1L) != !range1.contains(element17)) throw AssertionError() + if (!(element17 !in 3L until 1L) != range1.contains(element17)) throw AssertionError() +} + +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() + // 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() + if (!(element18 in 3L until 1L) != !range1.contains(element18)) throw AssertionError() + if (!(element18 !in 3L until 1L) != range1.contains(element18)) throw AssertionError() +} + +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() + // 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() + if (!(element19 in 3L until 1L) != !range1.contains(element19)) throw AssertionError() + if (!(element19 !in 3L until 1L) != range1.contains(element19)) throw AssertionError() +} + +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() + // 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() + if (!(element20 in 3L until 1L) != !range1.contains(element20)) throw AssertionError() + if (!(element20 !in 3L until 1L) != range1.contains(element20)) throw AssertionError() +} + +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() + // 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() + if (!(element21 in 3L until 1L) != !range1.contains(element21)) throw AssertionError() + if (!(element21 !in 3L until 1L) != range1.contains(element21)) throw AssertionError() +} + +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() + // 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() + if (!(element22 in 3L until 1L) != !range1.contains(element22)) throw AssertionError() + if (!(element22 !in 3L until 1L) != range1.contains(element22)) throw AssertionError() +} + +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() + // 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() + if (!(element23 in 3L until 1L) != !range1.contains(element23)) throw AssertionError() + 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/inArrayIndices.kt b/compiler/testData/codegen/box/ranges/contains/inArrayIndices.kt deleted file mode 100644 index df6931c18b3..00000000000 --- a/compiler/testData/codegen/box/ranges/contains/inArrayIndices.kt +++ /dev/null @@ -1,21 +0,0 @@ -// WITH_RUNTIME - -val ints = intArrayOf(1, 2, 3) -val objs = arrayOf(1, 2, 3) - -val i1 = 1 - -fun box(): String { - // NB partially const-folded in JVM BE - if (!(1 in ints.indices)) return "Fail 1 in IntArray.indices" - if (1 !in ints.indices) return "Fail 1 !in IntArray.indices" - if (!(1 in objs.indices)) return "Fail 1 in Array.indices" - if (1 !in objs.indices) return "Fail 1 !in Array.indices" - - if (!(i1 in ints.indices)) return "Fail i1 in IntArray.indices" - if (i1 !in ints.indices) return "Fail i1 !in IntArray.indices" - if (!(i1 in objs.indices)) return "Fail i1 in Array.indices" - if (i1 !in objs.indices) return "Fail i1 !in Array.indices" - - return "OK" -} diff --git a/compiler/testData/codegen/box/ranges/contains/inCharSequenceIndices.kt b/compiler/testData/codegen/box/ranges/contains/inCharSequenceIndices.kt deleted file mode 100644 index b26ebcee65d..00000000000 --- a/compiler/testData/codegen/box/ranges/contains/inCharSequenceIndices.kt +++ /dev/null @@ -1,16 +0,0 @@ -// WITH_RUNTIME - -val cs = "123" - -val i1 = 1 - -fun box(): String { - // NB partially const-folded in JVM BE - if (!(1 in cs.indices)) return "Fail 1 in CharSequence.indices" - if (1 !in cs.indices) return "Fail 1 !in CharSequence.indices" - - if (!(i1 in cs.indices)) return "Fail i1 in CharSequence.indices" - if (i1 !in cs.indices) return "Fail i1 !in CharSequence.indices" - - return "OK" -} diff --git a/compiler/testData/codegen/box/ranges/contains/inCollectionIndices.kt b/compiler/testData/codegen/box/ranges/contains/inCollectionIndices.kt deleted file mode 100644 index 0ac755d5bcc..00000000000 --- a/compiler/testData/codegen/box/ranges/contains/inCollectionIndices.kt +++ /dev/null @@ -1,16 +0,0 @@ -// WITH_RUNTIME - -val xs = listOf(1, 2, 3) - -val i1 = 1 - -fun box(): String { - // NB partially const-folded in JVM BE - if (!(1 in xs.indices)) return "Fail 1 in Collection.indices" - if (1 !in xs.indices) return "Fail 1 !in Collection.indices" - - if (!(i1 in xs.indices)) return "Fail i1 in Collection.indices" - if (i1 !in xs.indices) return "Fail i1 !in Collection.indices" - - return "OK" -} diff --git a/compiler/tests-ir-jvm/tests/org/jetbrains/kotlin/codegen/ir/IrBlackBoxCodegenTestGenerated.java b/compiler/tests-ir-jvm/tests/org/jetbrains/kotlin/codegen/ir/IrBlackBoxCodegenTestGenerated.java index 740c843d080..02598bdc049 100644 --- a/compiler/tests-ir-jvm/tests/org/jetbrains/kotlin/codegen/ir/IrBlackBoxCodegenTestGenerated.java +++ b/compiler/tests-ir-jvm/tests/org/jetbrains/kotlin/codegen/ir/IrBlackBoxCodegenTestGenerated.java @@ -13231,30 +13231,12 @@ public class IrBlackBoxCodegenTestGenerated extends AbstractIrBlackBoxCodegenTes doTest(fileName); } - @TestMetadata("inArrayIndices.kt") - public void testInArrayIndices() throws Exception { - String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inArrayIndices.kt"); - doTest(fileName); - } - @TestMetadata("inCharSequence.kt") public void testInCharSequence() throws Exception { String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inCharSequence.kt"); doTest(fileName); } - @TestMetadata("inCharSequenceIndices.kt") - public void testInCharSequenceIndices() throws Exception { - String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inCharSequenceIndices.kt"); - doTest(fileName); - } - - @TestMetadata("inCollectionIndices.kt") - public void testInCollectionIndices() throws Exception { - String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inCollectionIndices.kt"); - doTest(fileName); - } - @TestMetadata("inComparableRange.kt") public void testInComparableRange() throws Exception { String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inComparableRange.kt"); @@ -13380,6 +13362,99 @@ public class IrBlackBoxCodegenTestGenerated extends AbstractIrBlackBoxCodegenTes String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/rangeContainsString.kt"); doTest(fileName); } + + @TestMetadata("compiler/testData/codegen/box/ranges/contains/generated") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Generated extends AbstractIrBlackBoxCodegenTest { + public void testAllFilesPresentInGenerated() throws Exception { + KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/codegen/box/ranges/contains/generated"), Pattern.compile("^(.+)\\.kt$"), TargetBackend.JVM, true); + } + + @TestMetadata("arrayIndices.kt") + public void testArrayIndices() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/arrayIndices.kt"); + doTest(fileName); + } + + @TestMetadata("charDownTo.kt") + public void testCharDownTo() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charDownTo.kt"); + doTest(fileName); + } + + @TestMetadata("charRangeLiteral.kt") + public void testCharRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("charSequenceIndices.kt") + public void testCharSequenceIndices() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charSequenceIndices.kt"); + doTest(fileName); + } + + @TestMetadata("charUntil.kt") + public void testCharUntil() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charUntil.kt"); + doTest(fileName); + } + + @TestMetadata("collectionIndices.kt") + public void testCollectionIndices() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/collectionIndices.kt"); + doTest(fileName); + } + + @TestMetadata("doubleRangeLiteral.kt") + public void testDoubleRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/doubleRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("floatRangeLiteral.kt") + public void testFloatRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/floatRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("intDownTo.kt") + public void testIntDownTo() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/intDownTo.kt"); + doTest(fileName); + } + + @TestMetadata("intRangeLiteral.kt") + public void testIntRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/intRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("intUntil.kt") + public void testIntUntil() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/intUntil.kt"); + doTest(fileName); + } + + @TestMetadata("longDownTo.kt") + public void testLongDownTo() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/longDownTo.kt"); + doTest(fileName); + } + + @TestMetadata("longRangeLiteral.kt") + public void testLongRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/longRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("longUntil.kt") + public void testLongUntil() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/longUntil.kt"); + doTest(fileName); + } + } } @TestMetadata("compiler/testData/codegen/box/ranges/expression") diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxCodegenTestGenerated.java b/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxCodegenTestGenerated.java index b534272d147..58d52ce4574 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxCodegenTestGenerated.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxCodegenTestGenerated.java @@ -13231,30 +13231,12 @@ public class BlackBoxCodegenTestGenerated extends AbstractBlackBoxCodegenTest { doTest(fileName); } - @TestMetadata("inArrayIndices.kt") - public void testInArrayIndices() throws Exception { - String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inArrayIndices.kt"); - doTest(fileName); - } - @TestMetadata("inCharSequence.kt") public void testInCharSequence() throws Exception { String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inCharSequence.kt"); doTest(fileName); } - @TestMetadata("inCharSequenceIndices.kt") - public void testInCharSequenceIndices() throws Exception { - String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inCharSequenceIndices.kt"); - doTest(fileName); - } - - @TestMetadata("inCollectionIndices.kt") - public void testInCollectionIndices() throws Exception { - String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inCollectionIndices.kt"); - doTest(fileName); - } - @TestMetadata("inComparableRange.kt") public void testInComparableRange() throws Exception { String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inComparableRange.kt"); @@ -13380,6 +13362,99 @@ public class BlackBoxCodegenTestGenerated extends AbstractBlackBoxCodegenTest { String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/rangeContainsString.kt"); doTest(fileName); } + + @TestMetadata("compiler/testData/codegen/box/ranges/contains/generated") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Generated extends AbstractBlackBoxCodegenTest { + public void testAllFilesPresentInGenerated() throws Exception { + KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/codegen/box/ranges/contains/generated"), Pattern.compile("^(.+)\\.kt$"), TargetBackend.JVM, true); + } + + @TestMetadata("arrayIndices.kt") + public void testArrayIndices() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/arrayIndices.kt"); + doTest(fileName); + } + + @TestMetadata("charDownTo.kt") + public void testCharDownTo() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charDownTo.kt"); + doTest(fileName); + } + + @TestMetadata("charRangeLiteral.kt") + public void testCharRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("charSequenceIndices.kt") + public void testCharSequenceIndices() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charSequenceIndices.kt"); + doTest(fileName); + } + + @TestMetadata("charUntil.kt") + public void testCharUntil() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charUntil.kt"); + doTest(fileName); + } + + @TestMetadata("collectionIndices.kt") + public void testCollectionIndices() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/collectionIndices.kt"); + doTest(fileName); + } + + @TestMetadata("doubleRangeLiteral.kt") + public void testDoubleRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/doubleRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("floatRangeLiteral.kt") + public void testFloatRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/floatRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("intDownTo.kt") + public void testIntDownTo() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/intDownTo.kt"); + doTest(fileName); + } + + @TestMetadata("intRangeLiteral.kt") + public void testIntRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/intRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("intUntil.kt") + public void testIntUntil() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/intUntil.kt"); + doTest(fileName); + } + + @TestMetadata("longDownTo.kt") + public void testLongDownTo() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/longDownTo.kt"); + doTest(fileName); + } + + @TestMetadata("longRangeLiteral.kt") + public void testLongRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/longRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("longUntil.kt") + public void testLongUntil() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/longUntil.kt"); + doTest(fileName); + } + } } @TestMetadata("compiler/testData/codegen/box/ranges/expression") diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/LightAnalysisModeTestGenerated.java b/compiler/tests/org/jetbrains/kotlin/codegen/LightAnalysisModeTestGenerated.java index 4702dec42ca..f0544870b09 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/LightAnalysisModeTestGenerated.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/LightAnalysisModeTestGenerated.java @@ -13231,30 +13231,12 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes doTest(fileName); } - @TestMetadata("inArrayIndices.kt") - public void testInArrayIndices() throws Exception { - String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inArrayIndices.kt"); - doTest(fileName); - } - @TestMetadata("inCharSequence.kt") public void testInCharSequence() throws Exception { String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inCharSequence.kt"); doTest(fileName); } - @TestMetadata("inCharSequenceIndices.kt") - public void testInCharSequenceIndices() throws Exception { - String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inCharSequenceIndices.kt"); - doTest(fileName); - } - - @TestMetadata("inCollectionIndices.kt") - public void testInCollectionIndices() throws Exception { - String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inCollectionIndices.kt"); - doTest(fileName); - } - @TestMetadata("inComparableRange.kt") public void testInComparableRange() throws Exception { String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inComparableRange.kt"); @@ -13380,6 +13362,99 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/rangeContainsString.kt"); doTest(fileName); } + + @TestMetadata("compiler/testData/codegen/box/ranges/contains/generated") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Generated extends AbstractLightAnalysisModeTest { + public void testAllFilesPresentInGenerated() throws Exception { + KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/codegen/box/ranges/contains/generated"), Pattern.compile("^(.+)\\.kt$"), TargetBackend.JVM, true); + } + + @TestMetadata("arrayIndices.kt") + public void testArrayIndices() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/arrayIndices.kt"); + doTest(fileName); + } + + @TestMetadata("charDownTo.kt") + public void testCharDownTo() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charDownTo.kt"); + doTest(fileName); + } + + @TestMetadata("charRangeLiteral.kt") + public void testCharRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("charSequenceIndices.kt") + public void testCharSequenceIndices() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charSequenceIndices.kt"); + doTest(fileName); + } + + @TestMetadata("charUntil.kt") + public void testCharUntil() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charUntil.kt"); + doTest(fileName); + } + + @TestMetadata("collectionIndices.kt") + public void testCollectionIndices() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/collectionIndices.kt"); + doTest(fileName); + } + + @TestMetadata("doubleRangeLiteral.kt") + public void testDoubleRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/doubleRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("floatRangeLiteral.kt") + public void testFloatRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/floatRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("intDownTo.kt") + public void testIntDownTo() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/intDownTo.kt"); + doTest(fileName); + } + + @TestMetadata("intRangeLiteral.kt") + public void testIntRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/intRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("intUntil.kt") + public void testIntUntil() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/intUntil.kt"); + doTest(fileName); + } + + @TestMetadata("longDownTo.kt") + public void testLongDownTo() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/longDownTo.kt"); + doTest(fileName); + } + + @TestMetadata("longRangeLiteral.kt") + public void testLongRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/longRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("longUntil.kt") + public void testLongUntil() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/longUntil.kt"); + doTest(fileName); + } + } } @TestMetadata("compiler/testData/codegen/box/ranges/expression") diff --git a/generators/src/org/jetbrains/kotlin/generators/tests/GenerateInRangeExpressionTestData.kt b/generators/src/org/jetbrains/kotlin/generators/tests/GenerateInRangeExpressionTestData.kt new file mode 100644 index 00000000000..ed27d8251db --- /dev/null +++ b/generators/src/org/jetbrains/kotlin/generators/tests/GenerateInRangeExpressionTestData.kt @@ -0,0 +1,176 @@ +/* + * Copyright 2010-2017 JetBrains s.r.o. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.jetbrains.kotlin.generators.tests + +import java.io.File +import com.intellij.openapi.util.io.FileUtil +import java.io.PrintWriter +import java.io.StringWriter + +object GenerateInRangeExpressionTestData { + private val TEST_DATA_DIR = File("compiler/testData/codegen/box/ranges/contains") + private val GENERATED_DIR = File(TEST_DATA_DIR, "generated") + + private val PREAMBLE_MESSAGE = "Auto-generated by ${GenerateInRangeExpressionTestData::class.java.simpleName}. Do not edit!" + + private fun generateMatrixTestCase( + fileName: String, + rangeExpressions: List, + elementExpressions: List, + header: String = "" + ) { + PrintWriter(File(GENERATED_DIR, fileName)).use { + it.generateTestCaseBody(header, rangeExpressions, elementExpressions) + } + } + + private fun PrintWriter.generateTestCaseBody(header: String, rangeExpressions: List, elementExpressions: List) { + println("// $PREAMBLE_MESSAGE") + println("// WITH_RUNTIME") + println() + println(header) + println() + + val rangeValNames = generateGlobalValDefinitions(rangeExpressions, "range") + + val elementValNames = generateGlobalValDefinitions(elementExpressions, "element") + + val testFunctions = StringWriter() + val testFunctionsWriter = PrintWriter(testFunctions) + + println("fun box(): String {") + rangeValNames.zip(rangeExpressions).forEachIndexed { i, (rangeValName, rangeExpression) -> + elementValNames.zip(elementExpressions).forEachIndexed { j, (elementValName, elementExpression) -> + val functionName = "testR${i}xE${j}" + + println(" $functionName()") + + testFunctionsWriter.generateTestCaseFunction(functionName, rangeValName, rangeExpression, elementValName, elementExpression) + } + } + println(" return \"OK\"") + println("}") + println() + println(testFunctions.toString()) + } + + private fun PrintWriter.generateGlobalValDefinitions(expressions: List, prefix: String): List { + val valNames = expressions.indices.map { "$prefix$it" } + valNames.zip(expressions).forEach { (name, expression) -> println("val $name = $expression") } + println() + return valNames + } + + private fun PrintWriter.generateTestCaseFunction( + functionName: String, + rangeValName: String, + rangeExpression: String, + elementValName: String, + elementExpression: String + ) { + println("fun $functionName() {") + println(" // with possible local optimizations") + println(" if ($elementExpression in $rangeExpression != $rangeValName.contains($elementExpression)) throw AssertionError()") + println(" if ($elementExpression !in $rangeExpression != !$rangeValName.contains($elementExpression)) throw AssertionError()") + println(" if (!($elementExpression in $rangeExpression) != !$rangeValName.contains($elementExpression)) throw AssertionError()") + println(" if (!($elementExpression !in $rangeExpression) != $rangeValName.contains($elementExpression)) throw AssertionError()") + println(" // no local optimizations") + println(" if ($elementValName in $rangeExpression != $rangeValName.contains($elementValName)) throw AssertionError()") + println(" if ($elementValName !in $rangeExpression != !$rangeValName.contains($elementValName)) throw AssertionError()") + println(" if (!($elementValName in $rangeExpression) != !$rangeValName.contains($elementValName)) throw AssertionError()") + println(" if (!($elementValName !in $rangeExpression) != $rangeValName.contains($elementValName)) throw AssertionError()") + println("}") + println() + } + + private fun generateRangeOperatorTestCase( + name: String, + aExpression: String, + op: String, + bExpression: String, + elementExpressions: List + ) { + generateMatrixTestCase( + name, + listOf( + "$aExpression $op $bExpression", + "$bExpression $op $aExpression" + ), + elementExpressions + ) + } + + @JvmStatic + fun main(args: Array) { + if (!TEST_DATA_DIR.exists()) throw AssertionError("${TEST_DATA_DIR.path} doesn't exist") + + FileUtil.delete(GENERATED_DIR) + GENERATED_DIR.mkdirs() + + val charLiterals = listOf("'0'", "'1'", "'2'", "'3'", "'4'") + + val numericLiterals = + listOf("(-1)", "0", "1", "2", "3", "4").flatMap { + listOf("$it.toByte()", "$it.toShort()", it, "$it.toLong()", "$it.toFloat()", "$it.toDouble()") + } + + generateRangeOperatorTestCase("charRangeLiteral.kt", "'1'", "..", "'3'", charLiterals) + generateRangeOperatorTestCase("charUntil.kt", "'1'", "until", "'3'", charLiterals) + generateRangeOperatorTestCase("charDownTo.kt", "'3'", "downTo", "'1'", charLiterals) + + generateRangeOperatorTestCase("intRangeLiteral.kt", "1", "..", "3", numericLiterals) + generateRangeOperatorTestCase("intUntil.kt", "1", "until", "3", numericLiterals) + generateRangeOperatorTestCase("intDownTo.kt", "3", "downTo", "1", listOf("1")) + + generateRangeOperatorTestCase("longRangeLiteral.kt", "1L", "..", "3L", numericLiterals) + generateRangeOperatorTestCase("longUntil.kt", "1L", "until", "3L", numericLiterals) + generateRangeOperatorTestCase("longDownTo.kt", "3L", "downTo", "1L", listOf("1L")) + + generateRangeOperatorTestCase("floatRangeLiteral.kt", "1.0F", "..", "3.0F", numericLiterals) + + generateRangeOperatorTestCase("doubleRangeLiteral.kt", "1.0", "..", "3.0", numericLiterals) + + generateMatrixTestCase( + "arrayIndices.kt", + listOf("intArray.indices", "objectArray.indices", "emptyIntArray.indices", "emptyObjectArray.indices"), + numericLiterals, + """val intArray = intArrayOf(1, 2, 3) + |val objectArray = arrayOf(1, 2, 3) + |val emptyIntArray = intArrayOf() + |val emptyObjectArray = arrayOf() + """.trimMargin() + ) + + generateMatrixTestCase( + "collectionIndices.kt", + listOf("collection.indices", "emptyCollection.indices"), + numericLiterals, + """val collection = listOf(1, 2, 3) + |val emptyCollection = listOf() + """.trimMargin() + ) + + generateMatrixTestCase( + "charSequenceIndices.kt", + listOf("charSequence.indices", "emptyCharSequence.indices"), + numericLiterals, + """val charSequence: CharSequence = "123" + |val emptyCharSequence: CharSequence = "" + """.trimMargin() + ) + } +} \ No newline at end of file diff --git a/js/js.tests/test/org/jetbrains/kotlin/js/test/semantics/JsCodegenBoxTestGenerated.java b/js/js.tests/test/org/jetbrains/kotlin/js/test/semantics/JsCodegenBoxTestGenerated.java index fac97e6938e..5be6ffcd413 100644 --- a/js/js.tests/test/org/jetbrains/kotlin/js/test/semantics/JsCodegenBoxTestGenerated.java +++ b/js/js.tests/test/org/jetbrains/kotlin/js/test/semantics/JsCodegenBoxTestGenerated.java @@ -14845,30 +14845,12 @@ public class JsCodegenBoxTestGenerated extends AbstractJsCodegenBoxTest { doTest(fileName); } - @TestMetadata("inArrayIndices.kt") - public void testInArrayIndices() throws Exception { - String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inArrayIndices.kt"); - doTest(fileName); - } - @TestMetadata("inCharSequence.kt") public void testInCharSequence() throws Exception { String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inCharSequence.kt"); doTest(fileName); } - @TestMetadata("inCharSequenceIndices.kt") - public void testInCharSequenceIndices() throws Exception { - String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inCharSequenceIndices.kt"); - doTest(fileName); - } - - @TestMetadata("inCollectionIndices.kt") - public void testInCollectionIndices() throws Exception { - String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inCollectionIndices.kt"); - doTest(fileName); - } - @TestMetadata("inComparableRange.kt") public void testInComparableRange() throws Exception { String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/inComparableRange.kt"); @@ -15066,6 +15048,99 @@ public class JsCodegenBoxTestGenerated extends AbstractJsCodegenBoxTest { String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/rangeContainsString.kt"); doTest(fileName); } + + @TestMetadata("compiler/testData/codegen/box/ranges/contains/generated") + @TestDataPath("$PROJECT_ROOT") + @RunWith(JUnit3RunnerWithInners.class) + public static class Generated extends AbstractJsCodegenBoxTest { + public void testAllFilesPresentInGenerated() throws Exception { + KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("compiler/testData/codegen/box/ranges/contains/generated"), Pattern.compile("^(.+)\\.kt$"), TargetBackend.JS, true); + } + + @TestMetadata("arrayIndices.kt") + public void testArrayIndices() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/arrayIndices.kt"); + doTest(fileName); + } + + @TestMetadata("charDownTo.kt") + public void testCharDownTo() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charDownTo.kt"); + doTest(fileName); + } + + @TestMetadata("charRangeLiteral.kt") + public void testCharRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("charSequenceIndices.kt") + public void testCharSequenceIndices() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charSequenceIndices.kt"); + doTest(fileName); + } + + @TestMetadata("charUntil.kt") + public void testCharUntil() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/charUntil.kt"); + doTest(fileName); + } + + @TestMetadata("collectionIndices.kt") + public void testCollectionIndices() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/collectionIndices.kt"); + doTest(fileName); + } + + @TestMetadata("doubleRangeLiteral.kt") + public void testDoubleRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/doubleRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("floatRangeLiteral.kt") + public void testFloatRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/floatRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("intDownTo.kt") + public void testIntDownTo() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/intDownTo.kt"); + doTest(fileName); + } + + @TestMetadata("intRangeLiteral.kt") + public void testIntRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/intRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("intUntil.kt") + public void testIntUntil() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/intUntil.kt"); + doTest(fileName); + } + + @TestMetadata("longDownTo.kt") + public void testLongDownTo() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/longDownTo.kt"); + doTest(fileName); + } + + @TestMetadata("longRangeLiteral.kt") + public void testLongRangeLiteral() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/longRangeLiteral.kt"); + doTest(fileName); + } + + @TestMetadata("longUntil.kt") + public void testLongUntil() throws Exception { + String fileName = KotlinTestUtils.navigationMetadata("compiler/testData/codegen/box/ranges/contains/generated/longUntil.kt"); + doTest(fileName); + } + } } @TestMetadata("compiler/testData/codegen/box/ranges/expression")