On Wed, Nov 27, 2013 at 2:27 PM, Aaron Ballman <[email protected]>wrote:
> Author: aaronballman > Date: Wed Nov 27 07:27:02 2013 > New Revision: 195841 > > URL: http://llvm.org/viewvc/llvm-project?rev=195841&view=rev > Log: > Laying the basic groundwork for table generating the diagnostics for > attribute subjects. This makes some modifications to the way subjects are > listed in Attr.td, and updates the attr emitter to handle the new > constructs. > > I have disabled some attribute subject lines on purpose in Attr.td; > this part is a WIP with the goal being to restore those subjects > incrementally. By commenting them out, it leaves the original behavior > the same as before for those attributes and so those are not > functionality changes. > ... > @@ -4286,13 +3956,8 @@ static void handleObjCReturnsInnerPointe > static void handleObjCRequiresSuperAttr(Sema &S, Decl *D, > const AttributeList &attr) { > SourceLocation loc = attr.getLoc(); > This variable is unused. I'm going to remove it to fix the build, if you don't mind. > - ObjCMethodDecl *method = dyn_cast<ObjCMethodDecl>(D); > + ObjCMethodDecl *method = cast<ObjCMethodDecl>(D); > > - if (!method) { > - S.Diag(D->getLocStart(), diag::err_attribute_wrong_decl_type) > - << SourceRange(loc, loc) << attr.getName() << ExpectedMethod; > - return; > - } > DeclContext *DC = method->getDeclContext(); > if (const ObjCProtocolDecl *PDecl = > dyn_cast_or_null<ObjCProtocolDecl>(DC)) { > S.Diag(D->getLocStart(), diag::warn_objc_requires_super_protocol) > >
_______________________________________________ cfe-commits mailing list [email protected] http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
