Skip to content

[cherry-pick][lldb] Introduce an ImportedDeclaration and [lldb] Handle @_originallyDefinedIn #9763

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

Conversation

augusto2112
Copy link

[lldb] Introduce an ImportedDeclaration

Introduce a debug info independent type, ImportedDeclaration, which is
analogous to DWARF's DW_AT_imported_declaration, as well as a way to
search them by name.

(cherry picked from commit fbc062390a97e14a3bc69b1670ad25e6420ae9bf)

and

[lldb] Handle @_originallyDefinedIn

Types annotated with @_originallyDefinedIn don't live in the module
listed in their mangled name. To account for this, the compiler emits a
DW_TAG_imported_declaration for those types under the name of the
swiftmodule these types can be found at. This patch implements the logic
required to produce the mangled name that can be used in type
reconstruction to successfully find these types.

rdar://137146961
(cherry picked from commit ce1a9d565f537f81b3d40e67666c91e9cc178938)

Introduce a debug info independent type, ImportedDeclaration, which is
analogous to DWARF's DW_AT_imported_declaration, as well as a way to
search them by name.

(cherry picked from commit fbc0623)
@augusto2112
Copy link
Author

@augusto2112
Copy link
Author

Types annotated with @_originallyDefinedIn don't live in the module
listed in their mangled name. To account for this, the compiler emits a
DW_TAG_imported_declaration for those types under the name of the
swiftmodule these types can be found at. This patch implements the logic
required to produce the mangled name that can be used in type
reconstruction to successfully find these types.

rdar://137146961
(cherry picked from commit ce1a9d5)
@augusto2112 augusto2112 force-pushed the orig-defined-in-imported-decl-6 branch from a4464f5 to 15bb8ec Compare December 18, 2024 21:48
@augusto2112
Copy link
Author

@adrian-prantl
Copy link

test with swiftlang/swift#78271
@swift-ci test

1 similar comment
@augusto2112
Copy link
Author

test with swiftlang/swift#78271
@swift-ci test

@adrian-prantl adrian-prantl merged commit 4d9ab63 into swiftlang:swift/release/6.1 Dec 19, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants