diff --git a/clang/include/clang/Frontend/MultiplexConsumer.h b/clang/include/clang/Frontend/MultiplexConsumer.h index a7e0444885f1..4d31104cce18 100644 --- a/clang/include/clang/Frontend/MultiplexConsumer.h +++ b/clang/include/clang/Frontend/MultiplexConsumer.h @@ -40,8 +40,14 @@ public: void HandleInterestingDecl(DeclGroupRef D) override; void HandleTranslationUnit(ASTContext &Ctx) override; void HandleTagDeclDefinition(TagDecl *D) override; + void HandleTagDeclRequiredDefinition(const TagDecl *D) override; void HandleCXXImplicitFunctionInstantiation(FunctionDecl *D) override; void HandleTopLevelDeclInObjCContainer(DeclGroupRef D) override; + void HandleImplicitImportDecl(ImportDecl *D) override; + void HandleLinkerOptionPragma(llvm::StringRef Opts) override; + void HandleDetectMismatch(llvm::StringRef Name, + llvm::StringRef Value) override; + void HandleDependentLibrary(llvm::StringRef Lib) override; void CompleteTentativeDefinition(VarDecl *D) override; void HandleVTable(CXXRecordDecl *RD, bool DefinitionRequired) override; ASTMutationListener *GetASTMutationListener() override; diff --git a/clang/lib/Frontend/MultiplexConsumer.cpp b/clang/lib/Frontend/MultiplexConsumer.cpp index 058cee8244b3..0e933a3f165f 100644 --- a/clang/lib/Frontend/MultiplexConsumer.cpp +++ b/clang/lib/Frontend/MultiplexConsumer.cpp @@ -251,6 +251,11 @@ void MultiplexConsumer::HandleTagDeclDefinition(TagDecl *D) { Consumers[i]->HandleTagDeclDefinition(D); } +void MultiplexConsumer::HandleTagDeclRequiredDefinition(const TagDecl *D) { + for (size_t i = 0, e = Consumers.size(); i != e; ++i) + Consumers[i]->HandleTagDeclRequiredDefinition(D); +} + void MultiplexConsumer::HandleCXXImplicitFunctionInstantiation(FunctionDecl *D){ for (size_t i = 0, e = Consumers.size(); i != e; ++i) Consumers[i]->HandleCXXImplicitFunctionInstantiation(D); @@ -261,6 +266,26 @@ void MultiplexConsumer::HandleTopLevelDeclInObjCContainer(DeclGroupRef D) { Consumers[i]->HandleTopLevelDeclInObjCContainer(D); } +void MultiplexConsumer::HandleImplicitImportDecl(ImportDecl *D) { + for (size_t i = 0, e = Consumers.size(); i != e; ++i) + Consumers[i]->HandleImplicitImportDecl(D); +} + +void MultiplexConsumer::HandleLinkerOptionPragma(llvm::StringRef Opts) { + for (size_t i = 0, e = Consumers.size(); i != e; ++i) + Consumers[i]->HandleLinkerOptionPragma(Opts); +} + +void MultiplexConsumer::HandleDetectMismatch(llvm::StringRef Name, llvm::StringRef Value) { + for (size_t i = 0, e = Consumers.size(); i != e; ++i) + Consumers[i]->HandleDetectMismatch(Name, Value); +} + +void MultiplexConsumer::HandleDependentLibrary(llvm::StringRef Lib) { + for (size_t i = 0, e = Consumers.size(); i != e; ++i) + Consumers[i]->HandleDependentLibrary(Lib); +} + void MultiplexConsumer::CompleteTentativeDefinition(VarDecl *D) { for (size_t i = 0, e = Consumers.size(); i != e; ++i) Consumers[i]->CompleteTentativeDefinition(D); diff --git a/clang/test/CodeGenCXX/debug-info-class-limited.cpp b/clang/test/CodeGenCXX/Inputs/debug-info-class-limited.cpp similarity index 91% rename from clang/test/CodeGenCXX/debug-info-class-limited.cpp rename to clang/test/CodeGenCXX/Inputs/debug-info-class-limited.cpp index 92326f7b539b..31a026101bb6 100644 --- a/clang/test/CodeGenCXX/debug-info-class-limited.cpp +++ b/clang/test/CodeGenCXX/Inputs/debug-info-class-limited.cpp @@ -1,4 +1,3 @@ -// RUN: %clang -emit-llvm -fno-standalone-debug -g -S %s -o - | FileCheck %s // CHECK-DAG: [ DW_TAG_structure_type ] [PR16214] [line [[@LINE+1]], {{.*}} [def] struct PR16214 { diff --git a/clang/test/CodeGenCXX/debug-info-class-limited-plugin.test b/clang/test/CodeGenCXX/debug-info-class-limited-plugin.test new file mode 100644 index 000000000000..61d258d9ffc4 --- /dev/null +++ b/clang/test/CodeGenCXX/debug-info-class-limited-plugin.test @@ -0,0 +1,2 @@ +RUN: %clang_cc1 -emit-llvm -fno-standalone-debug -g -o - -load %llvmshlibdir/PrintFunctionNames%pluginext -add-plugin print-function-names %S/Inputs/debug-info-class-limited.cpp 2>&1 | FileCheck %S/Inputs/debug-info-class-limited.cpp +REQUIRES: plugins, examples diff --git a/clang/test/CodeGenCXX/debug-info-class-limited.test b/clang/test/CodeGenCXX/debug-info-class-limited.test new file mode 100644 index 000000000000..0b10728f3c97 --- /dev/null +++ b/clang/test/CodeGenCXX/debug-info-class-limited.test @@ -0,0 +1 @@ +RUN: %clang_cc1 -emit-llvm -fno-standalone-debug -g %S/Inputs/debug-info-class-limited.cpp -o - | FileCheck %S/Inputs/debug-info-class-limited.cpp