http://d.puremagic.com/issues/show_bug.cgi?id=3520



--- Comment #2 from David Simcha <dsim...@yahoo.com> 2009-11-16 20:20:16 PST ---
Oh yea, while we're on the subject of overflow in CustomFloat and I'm reading
the code, is this right?

// denormalized source value
static if (flags & Flags.allowDenorm)
{
    exponent = 0;
    fraction = cast(typeof(fraction_max)) value.fraction;
}

Or should it be (from the normal value branch):

static if (fractionBits >= value.fractionBits)
{
    fraction = cast(typeof(fraction_max))
    (value.fraction << (fractionBits - value.fractionBits));
}
else
{
    fraction = cast(typeof(fraction_max))
    (value.fraction >> (value.fractionBits - fractionBits));
}

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------

Reply via email to