aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/qml/jsruntime/qv4runtime.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/qml/jsruntime/qv4runtime.cpp b/src/qml/jsruntime/qv4runtime.cpp
index 57ad181030..b31e07b979 100644
--- a/src/qml/jsruntime/qv4runtime.cpp
+++ b/src/qml/jsruntime/qv4runtime.cpp
@@ -1758,6 +1758,8 @@ Bool Runtime::method_compareEqual(const Value &left, const Value &right)
return !left.isNaN();
if (left.type() == right.type()) {
+ if (left.isDouble() && left.doubleValue() == 0 && right.doubleValue() == 0)
+ return true; // this takes care of -0 == +0 (which obviously have different raw values)
if (!left.isManaged())
return false;
if (left.isString() == right.isString())