Hi Daniel,<br><br><div class="gmail_quote">On Tue, Jun 12, 2012 at 10:36 PM, Daniel Jasper <span dir="ltr"><<a href="mailto:djasper@google.com" target="_blank">djasper@google.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div>Please find the attached patch, which changes the RecursiveASTVisitor behavior for CXXForRangeStmts, for review.</div><div><br></div>Depending on whether a RecursiveASTVisitor should visit implicit declarations, we need to do different things when visiting a range-based for loop.<div>

<br></div><div>If visiting implicit declarations, we can simply visit all children as we currently do.</div><div><br></div><div>If not, we should explicitly visit the loop variable (but not its implicit initialization) and the range initialization. Otherwise, we would not visit the range initialization at all (although it is explicit) because it is part of an implicit VarDecl.</div>
</blockquote></div><br><div>The patch looks great, but please update the comment for shouldVisitImplicitDeclarations to indicate that it also controls whether we visit implicit expressions in some cases. (I'm wary of renaming it, because that might silently break external RAV users...)</div>