diff options
| author | Sebastian Redl <sebastian.redl@getdesigned.at> | 2011-04-24 16:28:06 +0000 |
|---|---|---|
| committer | Sebastian Redl <sebastian.redl@getdesigned.at> | 2011-04-24 16:28:06 +0000 |
| commit | ab238a7d1895201ad3d10fc961ca68105b3844fb (patch) | |
| tree | 35f13e5311908fff8776d51f1aef650b2d7c87e9 /clang/lib/Frontend | |
| parent | f830df4e9d1aa0c6971de46d0b8c899788443cb9 (diff) | |
| download | bcm5719-llvm-ab238a7d1895201ad3d10fc961ca68105b3844fb.tar.gz bcm5719-llvm-ab238a7d1895201ad3d10fc961ca68105b3844fb.zip | |
Synthesizing the definition of an implicit member is an AST modification, so notify any mutation listeners of it. This fixes a crasher in chained PCH, where an implicit destructor in a PCH gets a definition in a chained PCH, which is then lost. However, any further use of the destructor would cause its definition to be regenerated in the final file, hiding the bug.
llvm-svn: 130103
Diffstat (limited to 'clang/lib/Frontend')
| -rw-r--r-- | clang/lib/Frontend/MultiplexConsumer.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/lib/Frontend/MultiplexConsumer.cpp b/clang/lib/Frontend/MultiplexConsumer.cpp index ecad91f1f04..721bd05a98a 100644 --- a/clang/lib/Frontend/MultiplexConsumer.cpp +++ b/clang/lib/Frontend/MultiplexConsumer.cpp @@ -97,6 +97,7 @@ public: const ClassTemplateSpecializationDecl *D); virtual void AddedCXXTemplateSpecialization(const FunctionTemplateDecl *TD, const FunctionDecl *D); + virtual void CompletedImplicitDefinition(const FunctionDecl *D); private: std::vector<ASTMutationListener*> Listeners; }; @@ -132,6 +133,11 @@ void MultiplexASTMutationListener::AddedCXXTemplateSpecialization( for (size_t i = 0, e = Listeners.size(); i != e; ++i) Listeners[i]->AddedCXXTemplateSpecialization(TD, D); } +void MultiplexASTMutationListener::CompletedImplicitDefinition( + const FunctionDecl *D) { + for (size_t i = 0, e = Listeners.size(); i != e; ++i) + Listeners[i]->CompletedImplicitDefinition(D); +} } // end namespace clang |

