From b2acef05fdca7471dab772a544ea88ff3d3d4a5b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Branimir=20Karad=C5=BEi=C4=87?= Date: Mon, 26 Nov 2018 10:03:19 -0800 Subject: [PATCH] Removed constexpr from functions that use union cast. --- include/bx/inline/math.inl | 12 ++++++------ include/bx/math.h | 12 ++++++------ 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/include/bx/inline/math.inl b/include/bx/inline/math.inl index 774bb14..7d21cac 100644 --- a/include/bx/inline/math.inl +++ b/include/bx/inline/math.inl @@ -59,37 +59,37 @@ namespace bx return result; } - inline constexpr BX_CONST_FUNC bool isNan(float _f) + inline BX_CONST_FUNC bool isNan(float _f) { const uint32_t tmp = floatToBits(_f) & INT32_MAX; return tmp > UINT32_C(0x7f800000); } - inline constexpr BX_CONST_FUNC bool isNan(double _f) + inline BX_CONST_FUNC bool isNan(double _f) { const uint64_t tmp = doubleToBits(_f) & INT64_MAX; return tmp > UINT64_C(0x7ff0000000000000); } - inline constexpr BX_CONST_FUNC bool isFinite(float _f) + inline BX_CONST_FUNC bool isFinite(float _f) { const uint32_t tmp = floatToBits(_f) & INT32_MAX; return tmp < UINT32_C(0x7f800000); } - inline constexpr BX_CONST_FUNC bool isFinite(double _f) + inline BX_CONST_FUNC bool isFinite(double _f) { const uint64_t tmp = doubleToBits(_f) & INT64_MAX; return tmp < UINT64_C(0x7ff0000000000000); } - inline constexpr BX_CONST_FUNC bool isInfinite(float _f) + inline BX_CONST_FUNC bool isInfinite(float _f) { const uint32_t tmp = floatToBits(_f) & INT32_MAX; return tmp == UINT32_C(0x7f800000); } - inline constexpr BX_CONST_FUNC bool isInfinite(double _f) + inline BX_CONST_FUNC bool isInfinite(double _f) { const uint64_t tmp = doubleToBits(_f) & INT64_MAX; return tmp == UINT64_C(0x7ff0000000000000); diff --git a/include/bx/math.h b/include/bx/math.h index ddcbb2d..36d5b92 100644 --- a/include/bx/math.h +++ b/include/bx/math.h @@ -88,27 +88,27 @@ namespace bx /// Returns true if _f is a number that is NaN. /// - constexpr BX_CONST_FUNC bool isNan(float _f); + BX_CONST_FUNC bool isNan(float _f); /// Returns true if _f is a number that is NaN. /// - constexpr BX_CONST_FUNC bool isNan(double _f); + BX_CONST_FUNC bool isNan(double _f); /// Returns true if _f is not infinite and is not a NaN. /// - constexpr BX_CONST_FUNC bool isFinite(float _f); + BX_CONST_FUNC bool isFinite(float _f); /// Returns true if _f is not infinite and is not a NaN. /// - constexpr BX_CONST_FUNC bool isFinite(double _f); + BX_CONST_FUNC bool isFinite(double _f); /// Returns true if _f is infinite and is not a NaN. /// - constexpr BX_CONST_FUNC bool isInfinite(float _f); + BX_CONST_FUNC bool isInfinite(float _f); /// Returns true if _f is infinite and is not a NaN. /// - constexpr BX_CONST_FUNC bool isInfinite(double _f); + BX_CONST_FUNC bool isInfinite(double _f); /// Returns the largest integer value not greater than _f. ///