diff options
author | Simon Hausmann <simon.hausmann@digia.com> | 2013-08-12 12:45:24 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-08-12 16:21:59 +0200 |
commit | f76584d9b724c131914b62dd9caff17abf326a95 (patch) | |
tree | 6cc7c891f9a998b83a7cb1e3c181f83c551c7c49 /src | |
parent | 1f4427dae80712d07a25f8f2d49c187adcbecc6c (diff) |
Fix build on QNX
There is std::isnan and friends, but math.h also defines isnan as macro,
so std::isnan expands to std::whateverthemacrois and that fails to build.
So include math.h early on, get rid of the macros and then we can continue
to use std::isnan throughout the code base safely.
Change-Id: Ifee580fa2adff396eb6d6f064d4c095a896fb022
Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/qml/jsruntime/qv4global_p.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/qml/jsruntime/qv4global_p.h b/src/qml/jsruntime/qv4global_p.h index 34ce6aefde..c5a31eb555 100644 --- a/src/qml/jsruntime/qv4global_p.h +++ b/src/qml/jsruntime/qv4global_p.h @@ -59,6 +59,14 @@ inline bool signbit(double d) { return _copysign(1.0, d) < 0; } inline double trunc(double d) { return d > 0 ? floor(d) : ceil(d); } #endif +#if defined(Q_OS_QNX) +#include <math.h> +#undef isnan +#undef isfinite +#undef isinf +#undef signbit +#endif + QT_BEGIN_NAMESPACE namespace QV4 { |