diff options
Diffstat (limited to 'src/corelib/global')
-rw-r--r-- | src/corelib/global/qglobal.cpp | 6 | ||||
-rw-r--r-- | src/corelib/global/qversiontagging.h | 2 |
2 files changed, 5 insertions, 3 deletions
diff --git a/src/corelib/global/qglobal.cpp b/src/corelib/global/qglobal.cpp index bc93b1f477..934916514a 100644 --- a/src/corelib/global/qglobal.cpp +++ b/src/corelib/global/qglobal.cpp @@ -4268,8 +4268,10 @@ bool QInternal::activateCallbacks(Callback cb, void **parameters) Compares the floating point value \a p1 and \a p2 and returns \c true if they are considered equal, otherwise \c false. - Note that comparing values where either \a p1 or \a p2 is 0.0 will not work. - The solution to this is to compare against values greater than or equal to 1.0. + Note that comparing values where either \a p1 or \a p2 is 0.0 will not work, + nor does comparing values where one of the values is NaN or infinity. + If one of the values is always 0.0, use qFuzzyIsNull instead. If one of the + values is likely to be 0.0, one solution is to add 1.0 to both values. \snippet code/src_corelib_global_qglobal.cpp 46 diff --git a/src/corelib/global/qversiontagging.h b/src/corelib/global/qversiontagging.h index 1e276dc3e0..3ed02c7376 100644 --- a/src/corelib/global/qversiontagging.h +++ b/src/corelib/global/qversiontagging.h @@ -60,7 +60,7 @@ QT_BEGIN_NAMESPACE * There will only be one copy of the section in the output library or application. */ -#if defined(QT_BUILD_CORE_LIB) || defined(QT_BOOTSTRAPPED) || defined(QT_NO_VERSION_TAGGING) +#if defined(QT_BUILD_CORE_LIB) || defined(QT_BOOTSTRAPPED) || defined(QT_NO_VERSION_TAGGING) || defined(QT_STATIC) // don't make tags in QtCore, bootstrapped systems or if the user asked not to #elif defined(Q_CC_GNU) && !defined(Q_OS_ANDROID) # if defined(Q_PROCESSOR_X86) && (defined(Q_OS_LINUX) || defined(Q_OS_FREEBSD_KERNEL)) |