diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/llvm/DIBuilder.h | 13 | ||||
-rw-r--r-- | include/llvm/DebugInfo.h | 10 |
2 files changed, 16 insertions, 7 deletions
diff --git a/include/llvm/DIBuilder.h b/include/llvm/DIBuilder.h index 2c0f712a93..4ce884b736 100644 --- a/include/llvm/DIBuilder.h +++ b/include/llvm/DIBuilder.h @@ -37,7 +37,7 @@ namespace llvm { class DIType; class DIArray; class DIGlobalVariable; - class DIImportedModule; + class DIImportedEntity; class DINameSpace; class DIVariable; class DISubrange; @@ -577,9 +577,18 @@ namespace llvm { /// @param Context The scope this module is imported into /// @param NS The namespace being imported here /// @param Line Line number - DIImportedModule createImportedModule(DIScope Context, DINameSpace NS, + DIImportedEntity createImportedModule(DIScope Context, DINameSpace NS, unsigned Line); + /// \brief Create a descriptor for an imported function. + /// @param Context The scope this module is imported into + /// @param Decl The declaration (or definition) of a function, type, or + /// variable + /// @param Line Line number + DIImportedEntity createImportedDeclaration(DIScope Context, + DIDescriptor Decl, + unsigned Line); + /// insertDeclare - Insert a new llvm.dbg.declare intrinsic call. /// @param Storage llvm::Value of the variable /// @param VarInfo Variable's debug info descriptor. diff --git a/include/llvm/DebugInfo.h b/include/llvm/DebugInfo.h index f9b58f4770..1c7edc971b 100644 --- a/include/llvm/DebugInfo.h +++ b/include/llvm/DebugInfo.h @@ -125,7 +125,7 @@ namespace llvm { bool isTemplateTypeParameter() const; bool isTemplateValueParameter() const; bool isObjCProperty() const; - bool isImportedModule() const; + bool isImportedEntity() const; /// print - print descriptor. void print(raw_ostream &OS) const; @@ -200,7 +200,7 @@ namespace llvm { DIArray getRetainedTypes() const; DIArray getSubprograms() const; DIArray getGlobalVariables() const; - DIArray getImportedModules() const; + DIArray getImportedEntities() const; StringRef getSplitDebugFilename() const { return getStringField(12); } @@ -684,13 +684,13 @@ namespace llvm { }; /// \brief An imported module (C++ using directive or similar). - class DIImportedModule : public DIDescriptor { + class DIImportedEntity : public DIDescriptor { friend class DIDescriptor; void printInternal(raw_ostream &OS) const; public: - explicit DIImportedModule(const MDNode *N) : DIDescriptor(N) { } + explicit DIImportedEntity(const MDNode *N) : DIDescriptor(N) { } DIScope getContext() const { return getFieldAs<DIScope>(1); } - DINameSpace getNameSpace() const { return getFieldAs<DINameSpace>(2); } + DIDescriptor getEntity() const { return getFieldAs<DIDescriptor>(2); } unsigned getLineNumber() const { return getUnsignedField(3); } bool Verify() const; }; |