diff options
author | Caitlin Sadowski <supertri@google.com> | 2011-09-15 17:50:19 +0000 |
---|---|---|
committer | Caitlin Sadowski <supertri@google.com> | 2011-09-15 17:50:19 +0000 |
commit | 69f5d14bae44f05b22fa50bb87122a61081fcd57 (patch) | |
tree | d80b8f782358dceb4716ce5c4309775bb2627008 /lib/Sema/SemaDeclAttr.cpp | |
parent | cb96751b25a934b22402c1e4e0805db7608a5f2b (diff) |
Thread safety: cleaning up FIXME for trylocks
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139805 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaDeclAttr.cpp')
-rw-r--r-- | lib/Sema/SemaDeclAttr.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/Sema/SemaDeclAttr.cpp b/lib/Sema/SemaDeclAttr.cpp index a887ce8ac3..3deab0d671 100644 --- a/lib/Sema/SemaDeclAttr.cpp +++ b/lib/Sema/SemaDeclAttr.cpp @@ -540,23 +540,23 @@ static void handleTrylockFunAttr(Sema &S, Decl *D, const AttributeList &Attr, } SmallVector<Expr*, 2> Args; - Args.push_back(Attr.getArg(0)); //FIXME // check that all arguments are lockable objects if (!checkAttrArgsAreLockableObjs(S, D, Attr, Args, 1)) return; unsigned Size = Args.size(); - assert(Size == Attr.getNumArgs()); Expr **StartArg = Size == 0 ? 0 : &Args[0]; if (exclusive) D->addAttr(::new (S.Context) ExclusiveTrylockFunctionAttr(Attr.getRange(), S.Context, + Attr.getArg(0), StartArg, Size)); else D->addAttr(::new (S.Context) SharedTrylockFunctionAttr(Attr.getRange(), - S.Context, StartArg, - Size)); + S.Context, + Attr.getArg(0), + StartArg, Size)); } static void handleLocksRequiredAttr(Sema &S, Decl *D, const AttributeList &Attr, |