[cfe-commits] [Patch] Add a warning for for loops with conditions that do not change

Richard Trieu rtrieu at google.com
Thu Mar 22 16:20:22 PDT 2012

New patch for the for-loop warning.

Both visitors are now EvaluatedExprVisitor
The DeclExtractor, used on the conditional, works on a whitelist of Expr's
instead of a blacklist.
Fixed edge cases in the DeclMatcher with respect to LValueToRValue
conversions.  Some casts aren't directly on DeclRefExprs.
Added variable names to the warning.  Up to 4 variable names will be
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20120322/f7f7fbb5/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: loop-analysis3.patch
Type: application/octet-stream
Size: 13060 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20120322/f7f7fbb5/attachment.obj>

More information about the cfe-commits mailing list