From 933ac3a16b8b5fe1ce8a463828cdf51a9c701507 Mon Sep 17 00:00:00 2001 From: Dmitry Petrov Date: Tue, 14 Jan 2020 16:09:30 +0300 Subject: [PATCH] Fix nullable number comparisons in JS --- .../kotlin/codegen/ExpressionCodegen.java | 4 +- .../PrimitiveNumericComparisonCallChecker.kt | 22 +++++++--- .../generators/OperatorExpressionGenerator.kt | 12 +++--- .../box/binaryOp/compareWithBoxedDouble.kt | 1 - .../box/binaryOp/compareWithBoxedLong.kt | 1 - .../binaryOp/compareWithBoxedNotNullDouble.kt | 1 - .../binaryOp/compareWithBoxedNotNullLong.kt | 1 - .../codegen/box/binaryOp/eqNullableDoubles.kt | 42 +++++++++++++++++++ .../box/binaryOp/eqNullableDoublesWithTP.kt | 42 +++++++++++++++++++ .../codegen/BlackBoxCodegenTestGenerated.java | 10 +++++ .../LightAnalysisModeTestGenerated.java | 10 +++++ .../ir/FirBlackBoxCodegenTestGenerated.java | 10 +++++ .../ir/IrBlackBoxCodegenTestGenerated.java | 10 +++++ .../IrJsCodegenBoxTestGenerated.java | 10 +++++ .../semantics/JsCodegenBoxTestGenerated.java | 10 +++++ 15 files changed, 168 insertions(+), 18 deletions(-) create mode 100644 compiler/testData/codegen/box/binaryOp/eqNullableDoubles.kt create mode 100644 compiler/testData/codegen/box/binaryOp/eqNullableDoublesWithTP.kt diff --git a/compiler/backend/src/org/jetbrains/kotlin/codegen/ExpressionCodegen.java b/compiler/backend/src/org/jetbrains/kotlin/codegen/ExpressionCodegen.java index b4586ce0270..6d7d03a2e8e 100644 --- a/compiler/backend/src/org/jetbrains/kotlin/codegen/ExpressionCodegen.java +++ b/compiler/backend/src/org/jetbrains/kotlin/codegen/ExpressionCodegen.java @@ -3756,13 +3756,13 @@ public class ExpressionCodegen extends KtVisitor impleme @Nullable private static KotlinType getLeftOperandType(@Nullable PrimitiveNumericComparisonInfo numericComparisonInfo) { if (numericComparisonInfo == null) return null; - return numericComparisonInfo.getLeftType(); + return numericComparisonInfo.getLeftPrimitiveType(); } @Nullable private static KotlinType getRightOperandType(@Nullable PrimitiveNumericComparisonInfo numericComparisonInfo) { if (numericComparisonInfo == null) return null; - return numericComparisonInfo.getRightType(); + return numericComparisonInfo.getRightPrimitiveType(); } /*tries to use IEEE 754 arithmetic*/ diff --git a/compiler/frontend/src/org/jetbrains/kotlin/resolve/checkers/PrimitiveNumericComparisonCallChecker.kt b/compiler/frontend/src/org/jetbrains/kotlin/resolve/checkers/PrimitiveNumericComparisonCallChecker.kt index 9e1cf6b2981..463d7fbed80 100644 --- a/compiler/frontend/src/org/jetbrains/kotlin/resolve/checkers/PrimitiveNumericComparisonCallChecker.kt +++ b/compiler/frontend/src/org/jetbrains/kotlin/resolve/checkers/PrimitiveNumericComparisonCallChecker.kt @@ -21,6 +21,8 @@ import org.jetbrains.kotlin.utils.addToStdlib.firstNotNullResult class PrimitiveNumericComparisonInfo( val comparisonType: KotlinType, + val leftPrimitiveType: KotlinType, + val rightPrimitiveType: KotlinType, val leftType: KotlinType, val rightType: KotlinType ) @@ -49,14 +51,20 @@ object PrimitiveNumericComparisonCallChecker : CallChecker { rightTypes: List, comparison: KtExpression ) { - val leftPrimitiveType = leftTypes.findPrimitiveType() ?: return - val rightPrimitiveType = rightTypes.findPrimitiveType() ?: return + val leftPrimitiveOrNullableType = leftTypes.findPrimitiveOrNullablePrimitiveType() ?: return + val rightPrimitiveOrNullableType = rightTypes.findPrimitiveOrNullablePrimitiveType() ?: return + val leftPrimitiveType = leftPrimitiveOrNullableType.makeNotNullable() + val rightPrimitiveType = rightPrimitiveOrNullableType.makeNotNullable() val leastCommonType = leastCommonPrimitiveNumericType(leftPrimitiveType, rightPrimitiveType) trace.record( BindingContext.PRIMITIVE_NUMERIC_COMPARISON_INFO, comparison, - PrimitiveNumericComparisonInfo(leastCommonType, leftPrimitiveType, rightPrimitiveType) + PrimitiveNumericComparisonInfo( + leastCommonType, + leftPrimitiveType, rightPrimitiveType, + leftPrimitiveOrNullableType, rightPrimitiveOrNullableType + ) ) } @@ -90,15 +98,17 @@ object PrimitiveNumericComparisonCallChecker : CallChecker { return listOf(type) + stableTypes } - private fun List.findPrimitiveType() = + private fun List.findPrimitiveOrNullablePrimitiveType() = firstNotNullResult { it.getPrimitiveTypeOrSupertype() } private fun KotlinType.getPrimitiveTypeOrSupertype(): KotlinType? = when { constructor.declarationDescriptor is TypeParameterDescriptor -> - immediateSupertypes().firstNotNullResult { it.getPrimitiveTypeOrSupertype() } + immediateSupertypes().firstNotNullResult { + it.getPrimitiveTypeOrSupertype() + } isPrimitiveNumberOrNullableType() -> - makeNotNullable() + this else -> null } diff --git a/compiler/ir/ir.psi2ir/src/org/jetbrains/kotlin/psi2ir/generators/OperatorExpressionGenerator.kt b/compiler/ir/ir.psi2ir/src/org/jetbrains/kotlin/psi2ir/generators/OperatorExpressionGenerator.kt index f55f2a9be6d..b70e05a7ea0 100644 --- a/compiler/ir/ir.psi2ir/src/org/jetbrains/kotlin/psi2ir/generators/OperatorExpressionGenerator.kt +++ b/compiler/ir/ir.psi2ir/src/org/jetbrains/kotlin/psi2ir/generators/OperatorExpressionGenerator.kt @@ -326,8 +326,8 @@ class OperatorExpressionGenerator(statementGenerator: StatementGenerator) : Stat eqeqSymbol, context.irBuiltIns.booleanType, irOperator, - expression.left!!.generateAsPrimitiveNumericComparisonOperand(comparisonInfo?.leftType, comparisonType), - expression.right!!.generateAsPrimitiveNumericComparisonOperand(comparisonInfo?.rightType, comparisonType) + expression.left!!.generateAsPrimitiveNumericComparisonOperand(comparisonInfo?.leftPrimitiveType, comparisonType), + expression.right!!.generateAsPrimitiveNumericComparisonOperand(comparisonInfo?.rightPrimitiveType, comparisonType) ) return when (irOperator) { @@ -363,8 +363,8 @@ class OperatorExpressionGenerator(statementGenerator: StatementGenerator) : Stat eqeqSymbol, context.irBuiltIns.booleanType, irOperator, - arg1.promoteToPrimitiveNumericType(comparisonInfo.leftType, comparisonType), - arg2.promoteToPrimitiveNumericType(comparisonInfo.rightType, comparisonType) + arg1.promoteToPrimitiveNumericType(comparisonInfo.leftPrimitiveType, comparisonType), + arg2.promoteToPrimitiveNumericType(comparisonInfo.rightPrimitiveType, comparisonType) ) } else { primitiveOp2( @@ -456,8 +456,8 @@ class OperatorExpressionGenerator(statementGenerator: StatementGenerator) : Stat getComparisonOperatorSymbol(origin, kotlinTypeToIrType(comparisonType) ?: error("$comparisonType expected to be primitive")), context.irBuiltIns.booleanType, origin, - ktLeft.generateAsPrimitiveNumericComparisonOperand(comparisonInfo.leftType, comparisonInfo.comparisonType), - ktRight.generateAsPrimitiveNumericComparisonOperand(comparisonInfo.rightType, comparisonInfo.comparisonType) + ktLeft.generateAsPrimitiveNumericComparisonOperand(comparisonInfo.leftPrimitiveType, comparisonInfo.comparisonType), + ktRight.generateAsPrimitiveNumericComparisonOperand(comparisonInfo.rightPrimitiveType, comparisonInfo.comparisonType) ) } else { val resolvedCall = getResolvedCall(ktExpression) diff --git a/compiler/testData/codegen/box/binaryOp/compareWithBoxedDouble.kt b/compiler/testData/codegen/box/binaryOp/compareWithBoxedDouble.kt index 7c8868e0bd3..10684f1c621 100644 --- a/compiler/testData/codegen/box/binaryOp/compareWithBoxedDouble.kt +++ b/compiler/testData/codegen/box/binaryOp/compareWithBoxedDouble.kt @@ -1,6 +1,5 @@ // IGNORE_BACKEND_FIR: JVM_IR // TARGET_BACKEND: JVM -// reason - multifile tests are not supported in JS tests //FILE: Holder.java class Holder { diff --git a/compiler/testData/codegen/box/binaryOp/compareWithBoxedLong.kt b/compiler/testData/codegen/box/binaryOp/compareWithBoxedLong.kt index 7bb06a238dd..4ea96bca7ac 100644 --- a/compiler/testData/codegen/box/binaryOp/compareWithBoxedLong.kt +++ b/compiler/testData/codegen/box/binaryOp/compareWithBoxedLong.kt @@ -1,6 +1,5 @@ // IGNORE_BACKEND_FIR: JVM_IR // TARGET_BACKEND: JVM -// reason - multifile tests are not supported in JS tests //FILE: JavaClass.java class JavaClass { diff --git a/compiler/testData/codegen/box/binaryOp/compareWithBoxedNotNullDouble.kt b/compiler/testData/codegen/box/binaryOp/compareWithBoxedNotNullDouble.kt index d8521182e13..da09a2090c3 100644 --- a/compiler/testData/codegen/box/binaryOp/compareWithBoxedNotNullDouble.kt +++ b/compiler/testData/codegen/box/binaryOp/compareWithBoxedNotNullDouble.kt @@ -1,6 +1,5 @@ // IGNORE_BACKEND_FIR: JVM_IR // TARGET_BACKEND: JVM -// reason - multifile tests are not supported in JS tests //FILE: Holder.java import org.jetbrains.annotations.*; diff --git a/compiler/testData/codegen/box/binaryOp/compareWithBoxedNotNullLong.kt b/compiler/testData/codegen/box/binaryOp/compareWithBoxedNotNullLong.kt index 31d08f85a8d..089d65bcb67 100644 --- a/compiler/testData/codegen/box/binaryOp/compareWithBoxedNotNullLong.kt +++ b/compiler/testData/codegen/box/binaryOp/compareWithBoxedNotNullLong.kt @@ -1,6 +1,5 @@ // IGNORE_BACKEND_FIR: JVM_IR // TARGET_BACKEND: JVM -// reason - multifile tests are not supported in JS tests //FILE: JavaClass.java import org.jetbrains.annotations.*; diff --git a/compiler/testData/codegen/box/binaryOp/eqNullableDoubles.kt b/compiler/testData/codegen/box/binaryOp/eqNullableDoubles.kt new file mode 100644 index 00000000000..ba94a8fe774 --- /dev/null +++ b/compiler/testData/codegen/box/binaryOp/eqNullableDoubles.kt @@ -0,0 +1,42 @@ +// !LANGUAGE: +ProperIeee754Comparisons +// IGNORE_BACKEND: JS +// ^ if (eq_double_any(0.0, 0)) throw AssertionError("eq_double_any(0.0, 0)") + +fun eq_double_doubleN(a: Double, b: Double?) = a == b + +fun eq_double_any(a: Double, b: Any) = a == b + +fun eq_double_anyN(a: Double, b: Any?) = a == b + +fun eq_doubleN_double(a: Double?, b: Double) = a == b + +fun eq_doubleN_doubleN(a: Double?, b: Double?) = a == b + +fun eq_doubleN_any(a: Double?, b: Any) = a == b + +fun eq_doubleN_anyN(a: Double?, b: Any?) = a == b + +fun box(): String { + if (!eq_double_doubleN(0.0, -0.0)) throw AssertionError("!eq_double_doubleN(0.0, -0.0)") + if (eq_double_doubleN(0.0, null)) throw AssertionError("eq_double_doubleN(0.0, null)") + if (!eq_double_any(0.0, 0.0)) throw AssertionError("!eq_double_any(0.0, 0.0)") + if (eq_double_any(0.0, -0.0)) throw AssertionError("eq_double_any(0.0, -0.0)") + if (eq_double_any(0.0, 0)) throw AssertionError("eq_double_any(0.0, 0)") + if (!eq_double_anyN(0.0, 0.0)) throw AssertionError("!eq_double_anyN(0.0, 0.0)") + if (eq_double_anyN(0.0, -0.0)) throw AssertionError("eq_double_anyN(0.0, -0.0)") + if (eq_double_anyN(0.0, 0)) throw AssertionError("eq_double_anyN(0.0, 0)") + if (eq_double_anyN(0.0, null)) throw AssertionError("eq_double_anyN(0.0, null)") + + if (eq_doubleN_double(null, 0.0)) throw AssertionError("eq_doubleN_double(null, 0.0)") + if (!eq_doubleN_doubleN(0.0, -0.0)) throw AssertionError("!eq_doubleN_doubleN(0.0, -0.0)") + if (eq_doubleN_doubleN(0.0, null)) throw AssertionError("eq_doubleN_doubleN(0.0, null)") + if (!eq_doubleN_any(0.0, 0.0)) throw AssertionError("!eq_doubleN_any(0.0, 0.0)") + if (eq_doubleN_any(0.0, -0.0)) throw AssertionError("eq_doubleN_any(0.0, -0.0)") + if (eq_doubleN_any(0.0, 0)) throw AssertionError("eq_doubleN_any(0.0, 0)") + if (!eq_doubleN_anyN(0.0, 0.0)) throw AssertionError("!eq_doubleN_anyN(0.0, 0.0)") + if (eq_doubleN_anyN(0.0, -0.0)) throw AssertionError("eq_doubleN_anyN(0.0, -0.0)") + if (eq_doubleN_anyN(0.0, 0)) throw AssertionError("eq_doubleN_anyN(0.0, 0)") + if (eq_doubleN_anyN(0.0, null)) throw AssertionError("eq_doubleN_anyN(0.0, null)") + + return "OK" +} \ No newline at end of file diff --git a/compiler/testData/codegen/box/binaryOp/eqNullableDoublesWithTP.kt b/compiler/testData/codegen/box/binaryOp/eqNullableDoublesWithTP.kt new file mode 100644 index 00000000000..07fe79089c7 --- /dev/null +++ b/compiler/testData/codegen/box/binaryOp/eqNullableDoublesWithTP.kt @@ -0,0 +1,42 @@ +// !LANGUAGE: +ProperIeee754Comparisons +// IGNORE_BACKEND: JS +// ^ if (eq_double_any(0.0, 0)) throw AssertionError("eq_double_any(0.0, 0)") + +fun eq_double_doubleN(a: A, b: B) = a == b + +fun eq_double_any(a: A, b: B) = a == b + +fun eq_double_anyN(a: A, b: B) = a == b + +fun eq_doubleN_double(a: A, b: B) = a == b + +fun eq_doubleN_doubleN(a: A, b: B) = a == b + +fun eq_doubleN_any(a: A, b: B) = a == b + +fun eq_doubleN_anyN(a: A, b: B) = a == b + +fun box(): String { + if (!eq_double_doubleN(0.0, -0.0)) throw AssertionError("!eq_double_doubleN(0.0, -0.0)") + if (eq_double_doubleN(0.0, null)) throw AssertionError("eq_double_doubleN(0.0, null)") + if (!eq_double_any(0.0, 0.0)) throw AssertionError("!eq_double_any(0.0, 0.0)") + if (eq_double_any(0.0, -0.0)) throw AssertionError("eq_double_any(0.0, -0.0)") + if (eq_double_any(0.0, 0)) throw AssertionError("eq_double_any(0.0, 0)") + if (!eq_double_anyN(0.0, 0.0)) throw AssertionError("!eq_double_anyN(0.0, 0.0)") + if (eq_double_anyN(0.0, -0.0)) throw AssertionError("eq_double_anyN(0.0, -0.0)") + if (eq_double_anyN(0.0, 0)) throw AssertionError("eq_double_anyN(0.0, 0)") + if (eq_double_anyN(0.0, null)) throw AssertionError("eq_double_anyN(0.0, null)") + + if (eq_doubleN_double(null, 0.0)) throw AssertionError("eq_doubleN_double(null, 0.0)") + if (!eq_doubleN_doubleN(0.0, -0.0)) throw AssertionError("!eq_doubleN_doubleN(0.0, -0.0)") + if (eq_doubleN_doubleN(0.0, null)) throw AssertionError("eq_doubleN_doubleN(0.0, null)") + if (!eq_doubleN_any(0.0, 0.0)) throw AssertionError("!eq_doubleN_any(0.0, 0.0)") + if (eq_doubleN_any(0.0, -0.0)) throw AssertionError("eq_doubleN_any(0.0, -0.0)") + if (eq_doubleN_any(0.0, 0)) throw AssertionError("eq_doubleN_any(0.0, 0)") + if (!eq_doubleN_anyN(0.0, 0.0)) throw AssertionError("!eq_doubleN_anyN(0.0, 0.0)") + if (eq_doubleN_anyN(0.0, -0.0)) throw AssertionError("eq_doubleN_anyN(0.0, -0.0)") + if (eq_doubleN_anyN(0.0, 0)) throw AssertionError("eq_doubleN_anyN(0.0, 0)") + if (eq_doubleN_anyN(0.0, null)) throw AssertionError("eq_doubleN_anyN(0.0, null)") + + return "OK" +} \ No newline at end of file diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxCodegenTestGenerated.java b/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxCodegenTestGenerated.java index f32757a5852..d0d998d94f9 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxCodegenTestGenerated.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/BlackBoxCodegenTestGenerated.java @@ -1116,6 +1116,16 @@ public class BlackBoxCodegenTestGenerated extends AbstractBlackBoxCodegenTest { runTest("compiler/testData/codegen/box/binaryOp/divisionByZero.kt"); } + @TestMetadata("eqNullableDoubles.kt") + public void testEqNullableDoubles() throws Exception { + runTest("compiler/testData/codegen/box/binaryOp/eqNullableDoubles.kt"); + } + + @TestMetadata("eqNullableDoublesWithTP.kt") + public void testEqNullableDoublesWithTP() throws Exception { + runTest("compiler/testData/codegen/box/binaryOp/eqNullableDoublesWithTP.kt"); + } + @TestMetadata("intrinsic.kt") public void testIntrinsic() throws Exception { runTest("compiler/testData/codegen/box/binaryOp/intrinsic.kt"); diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/LightAnalysisModeTestGenerated.java b/compiler/tests/org/jetbrains/kotlin/codegen/LightAnalysisModeTestGenerated.java index 4e3ba51e808..d0983ab9300 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/LightAnalysisModeTestGenerated.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/LightAnalysisModeTestGenerated.java @@ -1116,6 +1116,16 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes runTest("compiler/testData/codegen/box/binaryOp/divisionByZero.kt"); } + @TestMetadata("eqNullableDoubles.kt") + public void testEqNullableDoubles() throws Exception { + runTest("compiler/testData/codegen/box/binaryOp/eqNullableDoubles.kt"); + } + + @TestMetadata("eqNullableDoublesWithTP.kt") + public void testEqNullableDoublesWithTP() throws Exception { + runTest("compiler/testData/codegen/box/binaryOp/eqNullableDoublesWithTP.kt"); + } + @TestMetadata("intrinsic.kt") public void testIntrinsic() throws Exception { runTest("compiler/testData/codegen/box/binaryOp/intrinsic.kt"); diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/ir/FirBlackBoxCodegenTestGenerated.java b/compiler/tests/org/jetbrains/kotlin/codegen/ir/FirBlackBoxCodegenTestGenerated.java index 30b1e615443..7346b9480cc 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/ir/FirBlackBoxCodegenTestGenerated.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/ir/FirBlackBoxCodegenTestGenerated.java @@ -1096,6 +1096,16 @@ public class FirBlackBoxCodegenTestGenerated extends AbstractFirBlackBoxCodegenT runTest("compiler/testData/codegen/box/binaryOp/divisionByZero.kt"); } + @TestMetadata("eqNullableDoubles.kt") + public void testEqNullableDoubles() throws Exception { + runTest("compiler/testData/codegen/box/binaryOp/eqNullableDoubles.kt"); + } + + @TestMetadata("eqNullableDoublesWithTP.kt") + public void testEqNullableDoublesWithTP() throws Exception { + runTest("compiler/testData/codegen/box/binaryOp/eqNullableDoublesWithTP.kt"); + } + @TestMetadata("intrinsic.kt") public void testIntrinsic() throws Exception { runTest("compiler/testData/codegen/box/binaryOp/intrinsic.kt"); diff --git a/compiler/tests/org/jetbrains/kotlin/codegen/ir/IrBlackBoxCodegenTestGenerated.java b/compiler/tests/org/jetbrains/kotlin/codegen/ir/IrBlackBoxCodegenTestGenerated.java index 135dcb57b38..7f6c6a24caa 100644 --- a/compiler/tests/org/jetbrains/kotlin/codegen/ir/IrBlackBoxCodegenTestGenerated.java +++ b/compiler/tests/org/jetbrains/kotlin/codegen/ir/IrBlackBoxCodegenTestGenerated.java @@ -1096,6 +1096,16 @@ public class IrBlackBoxCodegenTestGenerated extends AbstractIrBlackBoxCodegenTes runTest("compiler/testData/codegen/box/binaryOp/divisionByZero.kt"); } + @TestMetadata("eqNullableDoubles.kt") + public void testEqNullableDoubles() throws Exception { + runTest("compiler/testData/codegen/box/binaryOp/eqNullableDoubles.kt"); + } + + @TestMetadata("eqNullableDoublesWithTP.kt") + public void testEqNullableDoublesWithTP() throws Exception { + runTest("compiler/testData/codegen/box/binaryOp/eqNullableDoublesWithTP.kt"); + } + @TestMetadata("intrinsic.kt") public void testIntrinsic() throws Exception { runTest("compiler/testData/codegen/box/binaryOp/intrinsic.kt"); diff --git a/js/js.tests/test/org/jetbrains/kotlin/js/test/ir/semantics/IrJsCodegenBoxTestGenerated.java b/js/js.tests/test/org/jetbrains/kotlin/js/test/ir/semantics/IrJsCodegenBoxTestGenerated.java index f33f0780e42..d6271b5a5ec 100644 --- a/js/js.tests/test/org/jetbrains/kotlin/js/test/ir/semantics/IrJsCodegenBoxTestGenerated.java +++ b/js/js.tests/test/org/jetbrains/kotlin/js/test/ir/semantics/IrJsCodegenBoxTestGenerated.java @@ -756,6 +756,16 @@ public class IrJsCodegenBoxTestGenerated extends AbstractIrJsCodegenBoxTest { runTest("compiler/testData/codegen/box/binaryOp/divisionByZero.kt"); } + @TestMetadata("eqNullableDoubles.kt") + public void testEqNullableDoubles() throws Exception { + runTest("compiler/testData/codegen/box/binaryOp/eqNullableDoubles.kt"); + } + + @TestMetadata("eqNullableDoublesWithTP.kt") + public void testEqNullableDoublesWithTP() throws Exception { + runTest("compiler/testData/codegen/box/binaryOp/eqNullableDoublesWithTP.kt"); + } + @TestMetadata("intrinsic.kt") public void testIntrinsic() throws Exception { runTest("compiler/testData/codegen/box/binaryOp/intrinsic.kt"); 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 9abe1c4fc8b..2946748b41e 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 @@ -756,6 +756,16 @@ public class JsCodegenBoxTestGenerated extends AbstractJsCodegenBoxTest { runTest("compiler/testData/codegen/box/binaryOp/divisionByZero.kt"); } + @TestMetadata("eqNullableDoubles.kt") + public void testEqNullableDoubles() throws Exception { + runTest("compiler/testData/codegen/box/binaryOp/eqNullableDoubles.kt"); + } + + @TestMetadata("eqNullableDoublesWithTP.kt") + public void testEqNullableDoublesWithTP() throws Exception { + runTest("compiler/testData/codegen/box/binaryOp/eqNullableDoublesWithTP.kt"); + } + @TestMetadata("intrinsic.kt") public void testIntrinsic() throws Exception { runTest("compiler/testData/codegen/box/binaryOp/intrinsic.kt");