From 550b962059a97e7eb3cbc4543ef9ba40644bf486 Mon Sep 17 00:00:00 2001 From: "Duncan P. N. Exon Smith" Date: Tue, 7 Apr 2015 03:55:30 +0000 Subject: [PATCH] DebugInfo: Move DIFlag accessors from DIVariable to MDLocalVariable git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@234287 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/IR/DebugInfo.h | 10 ++-------- include/llvm/IR/DebugInfoMetadata.h | 3 +++ 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/include/llvm/IR/DebugInfo.h b/include/llvm/IR/DebugInfo.h index bfb725f65bc..c23cc4a7e4d 100644 --- a/include/llvm/IR/DebugInfo.h +++ b/include/llvm/IR/DebugInfo.h @@ -812,14 +812,8 @@ public: DIFile getFile() const { return DIFile(get()->getFile()); } DITypeRef getType() const { return DITypeRef::get(get()->getType()); } - /// \brief Return true if this variable is marked as "artificial". - bool isArtificial() const { - return (getFlags() & FlagArtificial) != 0; - } - - bool isObjectPointer() const { - return (getFlags() & FlagObjectPointer) != 0; - } + bool isArtificial() const { return get()->isArtificial(); } + bool isObjectPointer() const { return get()->isObjectPointer(); } /// \brief If this variable is inlined then return inline location. MDNode *getInlinedAt() const { return DIDescriptor(get()->getInlinedAt()); } diff --git a/include/llvm/IR/DebugInfoMetadata.h b/include/llvm/IR/DebugInfoMetadata.h index d4dff68911e..457e2952773 100644 --- a/include/llvm/IR/DebugInfoMetadata.h +++ b/include/llvm/IR/DebugInfoMetadata.h @@ -1769,6 +1769,9 @@ public: Metadata *getRawInlinedAt() const { return getOperand(4); } + bool isArtificial() const { return getFlags() & FlagArtificial; } + bool isObjectPointer() const { return getFlags() & FlagObjectPointer; } + /// \brief Check that a location is valid for this variable. /// /// Check that \c DL has the same inlined-at location as this variable, -- 2.34.1