[cfe-dev] Warning at always true condition
matthieu.monrocq at gmail.com
Thu Jun 14 11:28:32 PDT 2012
On Tue, Jun 12, 2012 at 2:04 AM, Seth Cantrell <bames53 at gmail.com> wrote:
> There's a -Weverything which I think you can use to check to see if a bit
> of code triggers any warnings.
> On Jun 11, 2012, at 7:10 AM, Devchandra L Meetei wrote:
> > Hi All
> > Does clang support any switch to warn about a conditional eg in if(p*
> !='h' || p* !='H'), which is always true.
> > Thankss in reply for timely response
> > Warm Reagrds
> > --Dev
> > _______________________________________________
> > cfe-dev mailing list
> > cfe-dev at cs.uiuc.edu
> > http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev
> cfe-dev mailing list
> cfe-dev at cs.uiuc.edu
Yes, this is actually the very purpose of -Weverything, it actives
everything so you can discover new warnings.
If the output is too verbose, the diagnostics tell you what flags activated
them so you can turn them off with the "no-" version: -Weverything
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the cfe-dev