[PATCH] D123452: [Clang] Override method ModuleImportRead in MultiplexASTDeserializationListener
Guoxiong Li via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Sat Apr 9 04:32:54 PDT 2022
lgxbslgx created this revision.
Herald added a project: All.
lgxbslgx requested review of this revision.
Herald added a project: clang.
Fixes https://github.com/llvm/llvm-project/issues/54521
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D123452
Files:
clang/include/clang/Frontend/MultiplexConsumer.h
clang/lib/Frontend/MultiplexConsumer.cpp
Index: clang/lib/Frontend/MultiplexConsumer.cpp
===================================================================
--- clang/lib/Frontend/MultiplexConsumer.cpp
+++ clang/lib/Frontend/MultiplexConsumer.cpp
@@ -73,6 +73,12 @@
Listener->ModuleRead(ID, Mod);
}
+void MultiplexASTDeserializationListener::ModuleImportRead(
+ serialization::SubmoduleID ID, SourceLocation ImportLoc) {
+ for (auto &Listener : Listeners)
+ Listener->ModuleImportRead(ID, ImportLoc);
+}
+
// This ASTMutationListener forwards its notifications to a set of
// child listeners.
class MultiplexASTMutationListener : public ASTMutationListener {
Index: clang/include/clang/Frontend/MultiplexConsumer.h
===================================================================
--- clang/include/clang/Frontend/MultiplexConsumer.h
+++ clang/include/clang/Frontend/MultiplexConsumer.h
@@ -40,6 +40,8 @@
void MacroDefinitionRead(serialization::PreprocessedEntityID,
MacroDefinitionRecord *MD) override;
void ModuleRead(serialization::SubmoduleID ID, Module *Mod) override;
+ void ModuleImportRead(serialization::SubmoduleID ID,
+ SourceLocation ImportLoc) override;
private:
std::vector<ASTDeserializationListener *> Listeners;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D123452.421715.patch
Type: text/x-patch
Size: 1272 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20220409/b834063f/attachment.bin>
More information about the cfe-commits
mailing list