[cfe-dev] ccache + clang warnings that are suppressed during macro expansion

Ted Kremenek kremenek at apple.com
Tue Sep 20 16:40:21 PDT 2011


On Sep 20, 2011, at 4:03 PM, David Blaikie wrote:

> (1) Clang suppresses some warnings in macro expansions, e.g. -Wparentheses-equality.
> 
> That seems rather not good. Do we do this deliberately (if so, why?), or is it just an accident/bug?
> 
> - David 


This is no accident.  I don't have an exhaustive list, but we do this in several cases.  The argument is that some warnings are almost always false positives when they result from macro expansions, but are very useful otherwise.  This of course leads to the problem that preprocessed files can have more warnings than the original source, but it does allow us to be more aggressive about putting various warnings under -Wall.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20110920/6b8aa582/attachment.html>


More information about the cfe-dev mailing list