[cfe-commits] r64927 - /cfe/trunk/lib/Sema/SemaDecl.cpp
Chris Lattner
clattner at apple.com
Wed Feb 18 14:59:44 PST 2009
On Feb 18, 2009, at 10:14 AM, Fariborz Jahanian wrote:
> Author: fjahanian
> Date: Wed Feb 18 12:14:41 2009
> New Revision: 64927
>
> URL: http://llvm.org/viewvc/llvm-project?rev=64927&view=rev
> Log:
> Make warn-weak-field.m test pass again.
Hi Fariborz,
How about adding some simple helper functions:
T.isObjCGCWeak() T.isObjCGCStrong()
?
-Chris
>
>
>
> Modified:
> cfe/trunk/lib/Sema/SemaDecl.cpp
>
> Modified: cfe/trunk/lib/Sema/SemaDecl.cpp
> URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaDecl.cpp?rev=64927&r1=64926&r2=64927&view=diff
>
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- cfe/trunk/lib/Sema/SemaDecl.cpp (original)
> +++ cfe/trunk/lib/Sema/SemaDecl.cpp Wed Feb 18 12:14:41 2009
> @@ -3501,6 +3501,8 @@
> }
>
> ProcessDeclAttributes(NewFD, D);
> + if (T.getObjCGCAttr() == QualType::Weak)
> + Diag(Loc, diag::warn_attribute_weak_on_field);
>
> if (D.getInvalidType() || InvalidDecl)
> NewFD->setInvalidDecl();
>
>
> _______________________________________________
> cfe-commits mailing list
> cfe-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
More information about the cfe-commits
mailing list