[interop][SwiftToCxx] Annotate emitted declarations with Clang's external_source_symbol attribute

Each emitted declaration is annotated with the external_source_symbol with its own USR, to allow Clang's indexer to recognize this declaration as a Swift declaration with a specific USR
This commit is contained in:
Alex Lorenz
2023-01-12 12:14:26 -08:00
parent 1d7c0ee7a5
commit 3b3d6c825a
58 changed files with 481 additions and 401 deletions

View File

@@ -32,6 +32,6 @@ public func testFunction() -> String {
return ""
}
// CHECK: namespace Swift __attribute__((swift_private)) {
// CHECK: namespace SwiftMod __attribute__((swift_private)) {
// CHECK: namespace Swift __attribute__((swift_private)) SWIFT_SYMBOL_MODULE("Swift") {
// CHECK: namespace SwiftMod __attribute__((swift_private)) SWIFT_SYMBOL_MODULE("SwiftMod") {
// CHECK-NOT: namespace Swift {