Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SR-15014] Large Decimals do not print correctly in the Swift REPL #4307

Open
saagarjha opened this issue Aug 3, 2021 · 1 comment
Open
Labels
bug Something isn't working Foundation LLDB for Swift

Comments

@saagarjha
Copy link

Previous ID SR-15014
Radar rdar://problem/81467525
Original Reporter @saagarjha
Type Bug
Environment

Xcode Version 13.0 beta 4 (13A5201i)/macOS Monterey 12.0 Beta (21A5294g)

Additional Detail from JIRA
Votes 0
Component/s Foundation, LLDB for Swift
Labels Bug
Assignee None
Priority Medium

md5: 2c5d3fbcb8a6920685afce84c7d9a1ca

Issue Description:

Large Decimal s don't seem to print correctly in the REPL:

$ swift
Welcome to Apple Swift version 5.5 (swiftlang-1300.0.27.6 clang-1300.0.27.2).
Type :help for assistance.
  1> import Foundation
  2> Decimal.greatestFiniteMagnitude
$R0: Decimal = 3402823669209386527134573422587986984989120495220592886182567909030848074563371292545093099671415093659185923505550104482059460129780644035015876086272801474166652928.000000

  3> print(Decimal.greatestFiniteMagnitude)
3402823669209384634633746074317682114550000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
  4>

The extra precision is not actually present in the backing for the number so it's unclear where LLDB is getting it from.

@typesanitizer
Copy link

@swift-ci create

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
@shahmishal shahmishal transferred this issue from apple/swift May 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Foundation LLDB for Swift
Projects
None yet
Development

No branches or pull requests

2 participants