From 3dc20f25cfcf279a4fe5eecbb42ec7098ce823d2 Mon Sep 17 00:00:00 2001 From: Redstone1024 <2824517378@qq.com> Date: Wed, 4 Dec 2024 11:41:32 +0800 Subject: [PATCH] fix(numeric): fix floating point classification function return value type --- Redcraft.Utility/Source/Public/Numeric/Math.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Redcraft.Utility/Source/Public/Numeric/Math.h b/Redcraft.Utility/Source/Public/Numeric/Math.h index 73803c8..073941c 100644 --- a/Redcraft.Utility/Source/Public/Numeric/Math.h +++ b/Redcraft.Utility/Source/Public/Numeric/Math.h @@ -436,7 +436,7 @@ RESOLVE_ARITHMETIC_AMBIGUITY_2_ARGS(CArithmetic, IsNearlyZero) /* @return true if the given value is infinity, false otherwise. */ template -NODISCARD FORCEINLINE constexpr T IsInfinity(T A) +NODISCARD FORCEINLINE constexpr bool IsInfinity(T A) { using Traits = NAMESPACE_PRIVATE::TFloatingTypeTraits; @@ -447,7 +447,7 @@ NODISCARD FORCEINLINE constexpr T IsInfinity(T A) /* @return true if the given value is NaN, false otherwise. */ template -NODISCARD FORCEINLINE constexpr T IsNaN(T A) +NODISCARD FORCEINLINE constexpr bool IsNaN(T A) { using Traits = NAMESPACE_PRIVATE::TFloatingTypeTraits; @@ -458,7 +458,7 @@ NODISCARD FORCEINLINE constexpr T IsNaN(T A) /* @return true if the given value is normal, false otherwise. */ template -NODISCARD FORCEINLINE constexpr T IsNormal(T A) +NODISCARD FORCEINLINE constexpr bool IsNormal(T A) { using Traits = NAMESPACE_PRIVATE::TFloatingTypeTraits; @@ -469,7 +469,7 @@ NODISCARD FORCEINLINE constexpr T IsNormal(T A) /* @return true if the given value is subnormal, false otherwise. */ template -NODISCARD FORCEINLINE constexpr T IsDenorm(T A) +NODISCARD FORCEINLINE constexpr bool IsDenorm(T A) { using Traits = NAMESPACE_PRIVATE::TFloatingTypeTraits;