mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-11-01 15:11:24 +00:00
DebugInfo: Use DebugNodeRef in MDImportedEntity::getEntity()
A quick cleanup to sue `DebugNodeRef` instead of `Metadata*` for `MDImportedEntity::getEntity()`. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@234288 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
550b962059
commit
351071c069
@ -2020,7 +2020,7 @@ class MDImportedEntity : public DebugNode {
|
||||
~MDImportedEntity() {}
|
||||
|
||||
static MDImportedEntity *getImpl(LLVMContext &Context, unsigned Tag,
|
||||
MDScope *Scope, Metadata *Entity,
|
||||
MDScope *Scope, DebugNodeRef Entity,
|
||||
unsigned Line, StringRef Name,
|
||||
StorageType Storage,
|
||||
bool ShouldCreate = true) {
|
||||
@ -2040,7 +2040,7 @@ class MDImportedEntity : public DebugNode {
|
||||
|
||||
public:
|
||||
DEFINE_MDNODE_GET(MDImportedEntity,
|
||||
(unsigned Tag, MDScope *Scope, Metadata *Entity,
|
||||
(unsigned Tag, MDScope *Scope, DebugNodeRef Entity,
|
||||
unsigned Line, StringRef Name = ""),
|
||||
(Tag, Scope, Entity, Line, Name))
|
||||
DEFINE_MDNODE_GET(MDImportedEntity,
|
||||
@ -2052,7 +2052,7 @@ public:
|
||||
|
||||
unsigned getLine() const { return Line; }
|
||||
MDScope *getScope() const { return cast_or_null<MDScope>(getRawScope()); }
|
||||
Metadata *getEntity() const { return getRawEntity(); }
|
||||
DebugNodeRef getEntity() const { return DebugNodeRef(getRawEntity()); }
|
||||
StringRef getName() const { return getStringOperand(2); }
|
||||
|
||||
Metadata *getRawScope() const { return getOperand(0); }
|
||||
|
@ -174,7 +174,8 @@ static DIImportedEntity
|
||||
createImportedModule(LLVMContext &C, dwarf::Tag Tag, DIScope Context,
|
||||
Metadata *NS, unsigned Line, StringRef Name,
|
||||
SmallVectorImpl<TrackingMDNodeRef> &AllImportedModules) {
|
||||
DIImportedEntity M = MDImportedEntity::get(C, Tag, Context, NS, Line, Name);
|
||||
DIImportedEntity M =
|
||||
MDImportedEntity::get(C, Tag, Context, DebugNodeRef(NS), Line, Name);
|
||||
AllImportedModules.emplace_back(M.get());
|
||||
return M;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user