From af525266d4d0667fe1a6be589e0a83131a829783 Mon Sep 17 00:00:00 2001 From: Tillmann Karras Date: Sun, 23 Mar 2014 10:24:06 +0100 Subject: MathUtil: add constructors to IntFloat/IntDouble --- Source/Core/Common/MathUtil.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'Source/Core/Common/MathUtil.cpp') diff --git a/Source/Core/Common/MathUtil.cpp b/Source/Core/Common/MathUtil.cpp index eaff3f40ff..c7437cf533 100644 --- a/Source/Core/Common/MathUtil.cpp +++ b/Source/Core/Common/MathUtil.cpp @@ -15,8 +15,7 @@ namespace MathUtil u32 ClassifyDouble(double dvalue) { // TODO: Optimize the below to be as fast as possible. - IntDouble value; - value.d = dvalue; + IntDouble value(dvalue); u64 sign = value.i & DOUBLE_SIGN; u64 exp = value.i & DOUBLE_EXP; if (exp > DOUBLE_ZERO && exp < DOUBLE_EXP) @@ -55,8 +54,7 @@ u32 ClassifyDouble(double dvalue) u32 ClassifyFloat(float fvalue) { // TODO: Optimize the below to be as fast as possible. - IntFloat value; - value.f = fvalue; + IntFloat value(fvalue); u32 sign = value.i & FLOAT_SIGN; u32 exp = value.i & FLOAT_EXP; if (exp > FLOAT_ZERO && exp < FLOAT_EXP) -- cgit v1.2.3