aboutsummaryrefslogtreecommitdiffstats
path: root/qmljs_runtime.h
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@digia.com>2012-11-01 16:46:54 +0100
committerSimon Hausmann <simon.hausmann@digia.com>2012-11-01 17:04:19 +0100
commitc3bcb5a2f6df2c604e857dda321bf17e5f8d4f60 (patch)
tree0ff267a1afb670ce5bb645b336279fcb446197b9 /qmljs_runtime.h
parent6f931118d6940f3dc315613d870498145fcc0d26 (diff)
Fix === operator
Correctly handle the case where one of the two arguments is a double and the other an integer. Change-Id: I589ac46acc30180b025c7e377c0523cf0889f294 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'qmljs_runtime.h')
-rw-r--r--qmljs_runtime.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/qmljs_runtime.h b/qmljs_runtime.h
index 6b318849d8..1220118af4 100644
--- a/qmljs_runtime.h
+++ b/qmljs_runtime.h
@@ -1115,6 +1115,8 @@ inline uint __qmljs_cmp_in(Value left, Value right, Context *ctx)
inline Bool __qmljs_strict_equal(Value x, Value y)
{
+ if (x.isDouble() || y.isDouble())
+ return x.asDouble() == y.asDouble();
if (x.rawValue() == y.rawValue())
return true;
if (x.isString() && y.isString())