From 56a8e78869325453010fb6c41a5e2b9e6f8f1c95 Mon Sep 17 00:00:00 2001 From: Thierry Bastian Date: Wed, 20 May 2009 17:56:51 +0200 Subject: Fix a compile error on MSVC 64bits due to qhash casting a pointer. I tested it with 32 bits compilation and there is no warning any more. Task-number: 247325 Reviewed-by: ogoffart --- src/corelib/tools/qhash.h | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/corelib/tools/qhash.h b/src/corelib/tools/qhash.h index a18b531..632c422 100644 --- a/src/corelib/tools/qhash.h +++ b/src/corelib/tools/qhash.h @@ -97,10 +97,7 @@ Q_CORE_EXPORT uint qHash(const QBitArray &key); #endif template inline uint qHash(const T *key) { - if (sizeof(const T *) > sizeof(uint)) - return qHash(reinterpret_cast(key)); - else - return uint(reinterpret_cast(key)); + return qHash(reinterpret_cast(key)); } #if defined(Q_CC_MSVC) #pragma warning( pop ) -- cgit v0.12