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-7474] LLDB should run the AST verifier after doing any AST manipulations #4373

Closed
belkadan opened this issue Apr 18, 2018 · 2 comments
Closed

Comments

@belkadan
Copy link

Previous ID SR-7474
Radar rdar://problem/39544116
Original Reporter @belkadan
Type Improvement
Status Resolved
Resolution Done
Additional Detail from JIRA
Votes 0
Component/s LLDB for Swift
Labels Improvement
Assignee @dcci
Priority Medium

md5: d3b4d71d74559c6d3ff1fae03d6073ec

Issue Description:

In apple/swift#15996 I'm adding a check to the Swift AST verifier that open is not used on declarations where it doesn't make sense (like a typealias). However, LLDB's unilaterally splatting open and public on things defined in the REPL to make sure they can be accessed later. That's a fine thing to do, but the condition where it was doing so wasn't quite right. I'm fixing that, but I couldn't write a real test for it because the AST verifier runs as part of Swift type checking, and is not run again after LLDB does its manipulation.

LLDB should call swift::verify(SourceFile &SF) (which is a no-op in release builds) after it does any AST manipulation, to make sure that the resulting AST still matches what the later phases of the compiler will expect.

@dcci
Copy link
Mannequin

dcci mannequin commented Apr 18, 2018

@swift-ci create

@dcci
Copy link
Mannequin

dcci mannequin commented Apr 26, 2018

Fixed apple/swift-lldb#570

@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
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant