summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorPeter Collingbourne <peter@pcc.me.uk>2013-08-02 22:34:30 +0000
committerPeter Collingbourne <peter@pcc.me.uk>2013-08-02 22:34:30 +0000
commit40bacacad3dac9eb5202193f685719d0f37d7f4a (patch)
tree9d98ad3b785a976c8b8005d34e31c1d5408a3764 /lib
parent7bba9c5c0a5235f585ee4bd3efec29e0982de3f8 (diff)
downloadllvm-40bacacad3dac9eb5202193f685719d0f37d7f4a.tar.gz
llvm-40bacacad3dac9eb5202193f685719d0f37d7f4a.tar.bz2
llvm-40bacacad3dac9eb5202193f685719d0f37d7f4a.tar.xz
Add a AttributeSetImpl::dump function.
This is for the benefit of those of us with inferior debuggers which do not permit member function calls on value types. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@187685 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/IR/AttributeImpl.h2
-rw-r--r--lib/IR/Attributes.cpp4
2 files changed, 6 insertions, 0 deletions
diff --git a/lib/IR/AttributeImpl.h b/lib/IR/AttributeImpl.h
index 7bf9e8ab6b..9da3f9659e 100644
--- a/lib/IR/AttributeImpl.h
+++ b/lib/IR/AttributeImpl.h
@@ -258,6 +258,8 @@ public:
// FIXME: This atrocity is temporary.
uint64_t Raw(unsigned Index) const;
+
+ void dump() const;
};
} // end llvm namespace
diff --git a/lib/IR/Attributes.cpp b/lib/IR/Attributes.cpp
index c4834671ac..f466d167e9 100644
--- a/lib/IR/Attributes.cpp
+++ b/lib/IR/Attributes.cpp
@@ -508,6 +508,10 @@ uint64_t AttributeSetImpl::Raw(unsigned Index) const {
return 0;
}
+void AttributeSetImpl::dump() const {
+ AttributeSet(const_cast<AttributeSetImpl *>(this)).dump();
+}
+
//===----------------------------------------------------------------------===//
// AttributeSet Construction and Mutation Methods
//===----------------------------------------------------------------------===//