diff options
author | Bill Wendling <isanbard@gmail.com> | 2012-10-09 00:51:40 +0000 |
---|---|---|
committer | Bill Wendling <isanbard@gmail.com> | 2012-10-09 00:51:40 +0000 |
commit | 3fa5709342500d827ffc3729b3fe1adf6bd14eaa (patch) | |
tree | 7b6377ae2afbd91a3938f7a4cee8e65ff3b674ce /lib/Transforms | |
parent | c40abb0b6853ccd7b32c9adb4487e7d8fbc13c09 (diff) |
Fix. Apply the no capture attribute to the correct parameter.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165469 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms')
-rw-r--r-- | lib/Transforms/Scalar/ObjCARC.cpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/lib/Transforms/Scalar/ObjCARC.cpp b/lib/Transforms/Scalar/ObjCARC.cpp index dbcafb0452..dca6a72fb1 100644 --- a/lib/Transforms/Scalar/ObjCARC.cpp +++ b/lib/Transforms/Scalar/ObjCARC.cpp @@ -3840,10 +3840,13 @@ Constant *ObjCARCContract::getStoreStrongCallee(Module *M) { Type *I8XX = PointerType::getUnqual(I8X); Type *Params[] = { I8XX, I8X }; - Attributes::Builder B; - B.addNoUnwindAttr(); - B.addNoCaptureAttr(); - AttrListPtr Attributes = AttrListPtr().addAttr(~0u, Attributes::get(B)); + Attributes::Builder BNoUnwind; + BNoUnwind.addNoUnwindAttr(); + Attributes::Builder BNoCapture; + BNoCapture.addNoCaptureAttr(); + AttrListPtr Attributes = AttrListPtr() + .addAttr(~0u, Attributes::get(BNoUnwind)) + .addAttr(1, Attributes::get(BNoCapture)); StoreStrongCallee = M->getOrInsertFunction( |