Add a AttributeSetImpl::dump function.
authorPeter Collingbourne <peter@pcc.me.uk>
Fri, 2 Aug 2013 22:34:30 +0000 (22:34 +0000)
committerPeter Collingbourne <peter@pcc.me.uk>
Fri, 2 Aug 2013 22:34:30 +0000 (22:34 +0000)
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

lib/IR/AttributeImpl.h
lib/IR/Attributes.cpp

index 7bf9e8ab6baecf3138e2d66b045617a8c6a0a6a5..9da3f9659e035ac397fb572b91e399a2a41ecb2d 100644 (file)
@@ -258,6 +258,8 @@ public:
 
   // FIXME: This atrocity is temporary.
   uint64_t Raw(unsigned Index) const;
+
+  void dump() const;
 };
 
 } // end llvm namespace
index c4834671ac614a6113579f0496a162b7e33693ff..f466d167e9724118f03e85595c98a8ce1410cc01 100644 (file)
@@ -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
 //===----------------------------------------------------------------------===//