summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/mscorlib/shared/System/Number.Parsing.cs3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/mscorlib/shared/System/Number.Parsing.cs b/src/mscorlib/shared/System/Number.Parsing.cs
index 70fc9aea8c..c6ae34d050 100644
--- a/src/mscorlib/shared/System/Number.Parsing.cs
+++ b/src/mscorlib/shared/System/Number.Parsing.cs
@@ -956,6 +956,9 @@ namespace System
public static unsafe ulong Mantissa(double d) =>
*((ulong*)&d) & 0x000fffffffffffff;
+
+ public static unsafe bool Sign(double d) =>
+ (*((uint*)&d + 1) >> 31) != 0;
}
}
}