System.Xml.XmlConverter.IsNegativeZero C# (CSharp) Method

IsNegativeZero() private static method

private static IsNegativeZero ( float value ) : bool
value float
return bool
        private static unsafe bool IsNegativeZero(float value)
        {
            // Simple equals function will report that -0 is equal to +0, so compare bits instead
            float negativeZero = -0e0F;
            return (*(Int32*)&value == *(Int32*)&negativeZero);
        }

Same methods

XmlConverter::IsNegativeZero ( double value ) : bool