aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp
diff options
context:
space:
mode:
authorQuietMisdreavus <QuietMisdreavus@users.noreply.github.com>2024-12-16 12:36:19 -0800
committerGitHub <noreply@github.com>2024-12-16 13:36:19 -0700
commit1be4a67454b02dae4df2368af31b5f655736d829 (patch)
tree7d95655b3da365995c2dba4ae0660ebb3c189a6c /clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp
parentf8656204d7ce2fd97c15ffa134212e0e3dc5f662 (diff)
downloadllvm-1be4a67454b02dae4df2368af31b5f655736d829.zip
llvm-1be4a67454b02dae4df2368af31b5f655736d829.tar.gz
llvm-1be4a67454b02dae4df2368af31b5f655736d829.tar.bz2
[ExtractAPI] reorder the module names in extension symbol graph file names (#119925)
Resolves rdar://140298287 ExtractAPI's support for printing Objective-C category extensions from other modules emits symbol graphs with an `ExtendedModule@HostModule.symbols.json`. However, this is backwards from existing symbol graph practices, causing issues when these symbol graphs are consumed alongside symbol graphs generated with other tools like Swift. This PR flips the naming scheme to be in line with existing symbol graph tooling.
Diffstat (limited to 'clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp')
-rw-r--r--clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp b/clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp
index c730c06..e881d56 100644
--- a/clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp
+++ b/clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp
@@ -1067,9 +1067,8 @@ void SymbolGraphSerializer::serializeWithExtensionGraphs(
for (auto &ExtensionSGF : Serializer.ExtendedModules) {
if (auto ExtensionOS =
- CreateOutputStream(ExtensionSGF.getKey() + "@" + API.ProductName))
- Serializer.serializeGraphToStream(*ExtensionOS, Options,
- ExtensionSGF.getKey(),
+ CreateOutputStream(API.ProductName + "@" + ExtensionSGF.getKey()))
+ Serializer.serializeGraphToStream(*ExtensionOS, Options, API.ProductName,
std::move(ExtensionSGF.getValue()));
}
}