[cfe-commits] r75477 - in /cfe/trunk/lib: CodeGen/CodeGenTypes.cpp Sema/SemaDecl.cpp Sema/SemaExpr.cpp Sema/SemaExprObjC.cpp

Chris Lattner clattner at apple.com
Mon Jul 13 11:32:54 PDT 2009


On Jul 13, 2009, at 10:19 AM, Steve Naroff wrote:

> Author: snaroff
> Date: Mon Jul 13 12:19:15 2009
> New Revision: 75477
>
> URL: http://llvm.org/viewvc/llvm-project?rev=75477&view=rev
> Log:
> Fix 5 issues from Chris's feedback on http://llvm.org/viewvc/llvm-project?view=rev&revision=75314 
> .
>
> Still more to come...just wanted to get the no-brainers out of the  
> way.

Thanks!

> @@ -4295,15 +4290,11 @@
>           << lType << rType << lex->getSourceRange() << rex- 
> >getSourceRange();
>       }
>       if (lType->isObjCQualifiedIdType() && rType- 
> >isObjCQualifiedIdType()) {
> +        if (!ObjCQualifiedIdTypesAreCompatible(lType, rType, true))
>           Diag(Loc, diag::warn_incompatible_qualified_id_operands)
>             << lType << rType << lex->getSourceRange() << rex- 
> >getSourceRange();
> +        ImpCastExprToType(rex, lType);
> +        return ResultTy;

Now you can delete this cast+return too :)

>       }
>       ImpCastExprToType(rex, lType);
>       return ResultTy;

-Chris



More information about the cfe-commits mailing list