summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@digia.com>2013-06-06 10:14:26 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-06-08 10:29:34 +0200
commit876202ddf29ddeb9fe74063d0590b2865c226cd0 (patch)
tree6b430b611fd300d3a2bc9c062b2ef0e71876e2b5 /tests
parent275c4b8403ddbdcd126cd55dfcc37bd1f5b6d9f7 (diff)
tst_qjson: Fix MSVC C4293 warning about shift operation.
warning C4293: '<<' : shift count negative or too big, undefined behavior. Change-Id: I858dd08f16ea0e00f2384491fc735b7367c6925d Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/corelib/json/tst_qtjson.cpp48
1 files changed, 24 insertions, 24 deletions
diff --git a/tests/auto/corelib/json/tst_qtjson.cpp b/tests/auto/corelib/json/tst_qtjson.cpp
index c19a42e4a6..6f5cda5307 100644
--- a/tests/auto/corelib/json/tst_qtjson.cpp
+++ b/tests/auto/corelib/json/tst_qtjson.cpp
@@ -252,18 +252,18 @@ void tst_QtJson::testNumbers()
0,
-1,
1,
- (1UL<<54),
- (1UL<<55),
- (1UL<<56),
- -(1UL<<54),
- -(1UL<<55),
- -(1UL<<56),
- (1UL<<54) - 1,
- (1UL<<55) - 1,
- (1UL<<56) - 1,
- -((1UL<<54) - 1),
- -((1UL<<55) - 1),
- -((1UL<<56) - 1)
+ (1ll<<54),
+ (1ll<<55),
+ (1ll<<56),
+ -(1ll<<54),
+ -(1ll<<55),
+ -(1ll<<56),
+ (1ll<<54) - 1,
+ (1ll<<55) - 1,
+ (1ll<<56) - 1,
+ -((1ll<<54) - 1),
+ -((1ll<<55) - 1),
+ -((1ll<<56) - 1)
};
int n = sizeof(numbers)/sizeof(qint64);
@@ -289,18 +289,18 @@ void tst_QtJson::testNumbers()
0,
-1,
1,
- (1UL<<54),
- (1UL<<55),
- (1UL<<56),
- -(1UL<<54),
- -(1UL<<55),
- -(1UL<<56),
- (1UL<<54) - 1,
- (1UL<<55) - 1,
- (1UL<<56) - 1,
- -((1UL<<54) - 1),
- -((1UL<<55) - 1),
- -((1UL<<56) - 1),
+ double(1ll<<54),
+ double(1ll<<55),
+ double(1ll<<56),
+ double(-(1ll<<54)),
+ double(-(1ll<<55)),
+ double(-(1ll<<56)),
+ double((1ll<<54) - 1),
+ double((1ll<<55) - 1),
+ double((1ll<<56) - 1),
+ double(-((1ll<<54) - 1)),
+ double(-((1ll<<55) - 1)),
+ double(-((1ll<<56) - 1)),
1.1,
0.1,
-0.1,