[cfe-commits] r163874 - /cfe/trunk/lib/Sema/SemaDecl.cpp

Jordan Rose jordan_rose at apple.com
Fri Sep 14 09:33:23 PDT 2012


What happened to the test case?

On Sep 13, 2012, at 22:10 , Douglas Gregor <dgregor at apple.com> wrote:

> Author: dgregor
> Date: Fri Sep 14 00:10:40 2012
> New Revision: 163874
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=163874&view=rev
> Log:
> Fix warning on qualified typedef with 'unused' attribute, from Jason Haslam!
> 
> 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=163874&r1=163873&r2=163874&view=diff
> ==============================================================================
> --- cfe/trunk/lib/Sema/SemaDecl.cpp (original)
> +++ cfe/trunk/lib/Sema/SemaDecl.cpp Fri Sep 14 00:10:40 2012
> @@ -1264,7 +1264,7 @@
>     QualType Ty = VD->getType();
> 
>     // Only look at the outermost level of typedef.
> -    if (const TypedefType *TT = dyn_cast<TypedefType>(Ty)) {
> +    if (const TypedefType *TT = Ty->getAs<TypedefType>()) {
>       if (TT->getDecl()->hasAttr<UnusedAttr>())
>         return false;
>     }
> 
> 
> _______________________________________________
> 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