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-12444] Xcode Debugger and lldb fail to display Foundation Types #4428

Open
phoney mannequin opened this issue Mar 29, 2020 · 4 comments
Open

[SR-12444] Xcode Debugger and lldb fail to display Foundation Types #4428

phoney mannequin opened this issue Mar 29, 2020 · 4 comments
Labels
bug Something isn't working LLDB for Swift

Comments

@phoney
Copy link
Mannequin

phoney mannequin commented Mar 29, 2020

Previous ID SR-12444
Radar rdar://problem/62201026
Original Reporter @phoney
Type Bug

Attachment: Download

Environment

Xcode Version 11.3.1 (11C505)

I ran this in the simulator but this also occurs on the device. I believe this bug has existed for several years.

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

md5: e4ee4a9163a24f83060d362f98f919e3

duplicates:

  • SR-11593 REPL incorrectly reports URL as nil

Issue Description:

The Xcode debugger fails to display some Foundation Types correctly

in the Variables Pane. lldb also fails to print these same types

correctly using 'frame v' and 'print' however it does correctly

print them using 'po'.

This is easily seen using the attached project. Set a breakpoint

on the print statement in the ViewController class and debug

the app. Once the breakpoint is hit some Foundation Types will

display correctly in the Variables Pane and will print correctly

using frame v and p. These include Data, NotificationName,

Notification and builtin types like Int, and Float. ClosedRange

also works as expected.

A number of other types fail to display correctly in the Varibles

Pane and also fail to print correctly with frame v and print. They do

print correctly with po. These include Date, TimeZone, URL, Calendar

DateComponents, IndexPath. I haven't tested every type so others

probably fail as well.

Optionals of these failing types always display as nil in the

Variables Pane and in lldb frame v even when they aren't nil.

All these types work as expected in a playground and the descriptions

displayed in a playground for these types is what I expect to see

in Xcode and in lldb.

I've attached the project, the playground, and a couple screenshots

of what this looks like in Xcode.

@beccadax
Copy link

beccadax commented Apr 17, 2020

@swift-ci create

@phoney
Copy link
Mannequin Author

phoney mannequin commented May 19, 2020

@poya
Copy link

poya commented May 20, 2020

Looks like duplicate of SR-11593

@swift-ci
Copy link

swift-ci commented Nov 11, 2020

Comment by Dave (JIRA)

@poya - despite the chronology I would say SR-11593 is a specific case of this root cause issue. If you want to close one as a duplicate, I would closed SR-11593 so focus stays on the root cause.

@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 LLDB for Swift
Projects
None yet
Development

No branches or pull requests

3 participants