diff options
Diffstat (limited to 'clang/lib/Sema/SemaDeclAttr.cpp')
-rw-r--r-- | clang/lib/Sema/SemaDeclAttr.cpp | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/clang/lib/Sema/SemaDeclAttr.cpp b/clang/lib/Sema/SemaDeclAttr.cpp index 8b3d738c60b..1f6e40164ca 100644 --- a/clang/lib/Sema/SemaDeclAttr.cpp +++ b/clang/lib/Sema/SemaDeclAttr.cpp @@ -4348,9 +4348,7 @@ static void handleObjCBridgeAttr(Sema &S, Scope *Sc, Decl *D, return; } - IdentifierLoc *Parm = 0; - if (Attr.getNumArgs() == 1) - Parm = Attr.isArgIdent(0) ? Attr.getArgAsIdent(0) : 0; + IdentifierLoc * Parm = Attr.isArgIdent(0) ? Attr.getArgAsIdent(0) : 0; if (!Parm) { S.Diag(D->getLocStart(), diag::err_objc_attr_not_id) << Attr.getName() << 0; @@ -4372,9 +4370,7 @@ static void handleObjCBridgeMutableAttr(Sema &S, Scope *Sc, Decl *D, return; } - IdentifierLoc *Parm = 0; - if (Attr.getNumArgs() == 1) - Parm = Attr.isArgIdent(0) ? Attr.getArgAsIdent(0) : 0; + IdentifierLoc * Parm = Attr.isArgIdent(0) ? Attr.getArgAsIdent(0) : 0; if (!Parm) { S.Diag(D->getLocStart(), diag::err_objc_attr_not_id) << Attr.getName() << 0; |