We found a workaround for this issue by replacing NSDecimalRound with the following helper (works when coming from a Double):
extension Double {
/// Helper for rounding a number to a fixed number of decimal places (`scale`).
///
/// This is a replacement for `NSDecimalRound`, which causes issues in release builds
/// with the Xcode 16 RC.
func roundedDecimal(scale: Int = 0, rule: FloatingPointRoundingRule = .toNearestOrEven) -> Decimal {
let significand = Decimal((self * pow(10, Double(scale))).rounded(rule))
return Decimal(sign: self.sign, exponent: -scale, significand: significand)
}
}
Topic:
Developer Tools & Services
SubTopic:
Xcode Cloud
Tags: