aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Transforms/Utils/CloneFunction.cpp
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2012-10-14 07:35:59 +0000
committerBill Wendling <isanbard@gmail.com>2012-10-14 07:35:59 +0000
commitc416795feaaa2052f7b46fa7a3f9b6ec3751b1eb (patch)
treea480d12bd585e710db7b7c25f37ec10eac7ce1cd /lib/Transforms/Utils/CloneFunction.cpp
parent432e606cf126e38f3f2a0a9f3348dfac34915bee (diff)
downloadexternal_llvm-c416795feaaa2052f7b46fa7a3f9b6ec3751b1eb.zip
external_llvm-c416795feaaa2052f7b46fa7a3f9b6ec3751b1eb.tar.gz
external_llvm-c416795feaaa2052f7b46fa7a3f9b6ec3751b1eb.tar.bz2
Remove the bitwise assignment OR operator from the Attributes class. Replace it with the equivalent from the builder class.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165895 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Utils/CloneFunction.cpp')
-rw-r--r--lib/Transforms/Utils/CloneFunction.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/Transforms/Utils/CloneFunction.cpp b/lib/Transforms/Utils/CloneFunction.cpp
index e293250..831f94a 100644
--- a/lib/Transforms/Utils/CloneFunction.cpp
+++ b/lib/Transforms/Utils/CloneFunction.cpp
@@ -98,10 +98,12 @@ void llvm::CloneFunctionInto(Function *NewFunc, const Function *OldFunc,
Anew->addAttr( OldFunc->getAttributes()
.getParamAttributes(I->getArgNo() + 1));
NewFunc->setAttributes(NewFunc->getAttributes()
- .addAttr(0, OldFunc->getAttributes()
+ .addAttr(NewFunc->getContext(), 0,
+ OldFunc->getAttributes()
.getRetAttributes()));
NewFunc->setAttributes(NewFunc->getAttributes()
- .addAttr(~0, OldFunc->getAttributes()
+ .addAttr(NewFunc->getContext(), ~0,
+ OldFunc->getAttributes()
.getFnAttributes()));
}