summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2012-10-16 05:55:09 +0000
committerBill Wendling <isanbard@gmail.com>2012-10-16 05:55:09 +0000
commit3ffbac4432012fdf7a3cd28790b76afb2fc51944 (patch)
tree5039cc98ce224aa037987670f807905317a71474 /llvm/lib
parent507c351a9a45babf2838e7866914b1661f721d08 (diff)
downloadbcm5719-llvm-3ffbac4432012fdf7a3cd28790b76afb2fc51944.tar.gz
bcm5719-llvm-3ffbac4432012fdf7a3cd28790b76afb2fc51944.zip
Have AttrBuilder defriend the Attributes class.
llvm-svn: 166011
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/VMCore/Attributes.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/VMCore/Attributes.cpp b/llvm/lib/VMCore/Attributes.cpp
index f028fd356d6..393eab0eef8 100644
--- a/llvm/lib/VMCore/Attributes.cpp
+++ b/llvm/lib/VMCore/Attributes.cpp
@@ -38,13 +38,13 @@ Attributes Attributes::get(LLVMContext &Context, ArrayRef<AttrVal> Vals) {
Attributes Attributes::get(LLVMContext &Context, AttrBuilder &B) {
// If there are no attributes, return an empty Attributes class.
- if (B.Bits == 0)
+ if (!B.hasAttributes())
return Attributes();
// Otherwise, build a key to look up the existing attributes.
LLVMContextImpl *pImpl = Context.pImpl;
FoldingSetNodeID ID;
- ID.AddInteger(B.Bits);
+ ID.AddInteger(B.Raw());
void *InsertPoint;
AttributesImpl *PA = pImpl->AttrsSet.FindNodeOrInsertPos(ID, InsertPoint);
@@ -52,7 +52,7 @@ Attributes Attributes::get(LLVMContext &Context, AttrBuilder &B) {
if (!PA) {
// If we didn't find any existing attributes of the same shape then create a
// new one and insert it.
- PA = new AttributesImpl(B.Bits);
+ PA = new AttributesImpl(B.Raw());
pImpl->AttrsSet.InsertNode(PA, InsertPoint);
}
OpenPOWER on IntegriCloud