Skip to content

Commit d013a2b

Browse files
authored
Fix Internal _mantissa problem on Windows (#125)
1 parent 114343a commit d013a2b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Sources/Floating Point Conversion.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ extension BigUInt {
4949
guard integer.sign == .plus else { return nil }
5050
assert(integer.floatingPointClass == .positiveNormal)
5151

52-
#if os(Linux)
52+
#if os(Linux) || os(Windows)
5353
// `Decimal._mantissa` has an internal access level on linux, and it might get
5454
// deprecated in the future, so keeping the string implementation around for now.
5555
let significand = BigUInt("\(integer.significand)")!
@@ -163,7 +163,7 @@ public extension Decimal {
163163
}
164164
#endif
165165

166-
#if canImport(Foundation) && !os(Linux)
166+
#if canImport(Foundation) && !(os(Linux) || os(Windows))
167167
private extension Decimal {
168168
var mantissaParts: [UInt16] {
169169
[

0 commit comments

Comments
 (0)