summaryrefslogtreecommitdiff
path: root/include/llvm
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2012-10-16 18:20:09 +0000
committerBill Wendling <isanbard@gmail.com>2012-10-16 18:20:09 +0000
commit79b319d35589ffe9c00a5e112a79ad20ea78c4d5 (patch)
tree0f47671c47e00418df6e259759bff0beff41564e /include/llvm
parentbedcbd433dbbba303df0ced76bec02b01b7b8f4d (diff)
downloadllvm-79b319d35589ffe9c00a5e112a79ad20ea78c4d5.tar.gz
llvm-79b319d35589ffe9c00a5e112a79ad20ea78c4d5.tar.bz2
llvm-79b319d35589ffe9c00a5e112a79ad20ea78c4d5.tar.xz
And now we can call the other 'get' method from this one and not duplicate the code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166037 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm')
-rw-r--r--include/llvm/Attributes.h9
1 files changed, 3 insertions, 6 deletions
diff --git a/include/llvm/Attributes.h b/include/llvm/Attributes.h
index 4222a62251..1e995f9a85 100644
--- a/include/llvm/Attributes.h
+++ b/include/llvm/Attributes.h
@@ -290,10 +290,7 @@ struct AttributeWithIndex {
static AttributeWithIndex get(LLVMContext &C, unsigned Idx,
ArrayRef<Attributes::AttrVal> Attrs) {
- AttributeWithIndex P;
- P.Index = Idx;
- P.Attrs = Attributes::get(C, Attrs);
- return P;
+ return get(Idx, Attributes::get(C, Attrs));
}
static AttributeWithIndex get(unsigned Idx, Attributes Attrs) {
AttributeWithIndex P;
@@ -318,8 +315,8 @@ public:
FunctionIndex = ~0U
};
private:
- /// AttrList - The attributes that we are managing. This can be null
- /// to represent the empty attributes list.
+ /// AttrList - The attributes that we are managing. This can be null to
+ /// represent the empty attributes list.
AttributeListImpl *AttrList;
public:
AttrListPtr() : AttrList(0) {}