Add Q_UINT64_C to 64 bit integer literal.
authorCarl Schumann <schumann@fnal.gov>
Tue, 15 May 2012 19:02:34 +0000 (14:02 -0500)
committerQt by Nokia <qt-info@nokia.com>
Tue, 15 May 2012 21:03:23 +0000 (23:03 +0200)
On some systems prior to this change the code
would not build with the following error reported
by gcc:
error: integer constant is too large for 'long' type

Change-Id: I778bce9a72ccf3a41cdf17883d734082ed3fb4b3
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
tests/auto/corelib/global/qtendian/tst_qtendian.cpp

index 002060b..51ff772 100644 (file)
@@ -72,7 +72,7 @@ union RawTestData
     TestData data;
 };
 
-static const TestData inNativeEndian = { 0x0123456789abcdef, 0x00c0ffee, 0xcafe, 0xcf, '\0' };
+static const TestData inNativeEndian = { Q_UINT64_C(0x0123456789abcdef), 0x00c0ffee, 0xcafe, 0xcf, '\0' };
 static const RawTestData inBigEndian = { "\x01\x23\x45\x67\x89\xab\xcd\xef" "\x00\xc0\xff\xee" "\xca\xfe" "\xcf" };
 static const RawTestData inLittleEndian = { "\xef\xcd\xab\x89\x67\x45\x23\x01" "\xee\xff\xc0\x00" "\xfe\xca" "\xcf" };