[cfe-dev] getting all function calls?

Joshua Cranmer Pidgeot18 at gmail.com
Thu Jun 9 11:16:07 PDT 2011


On 6/9/2011 10:15 AM, ret val wrote:
> Do you happen to know anything about the TraverseStmt() method from my 
> previous post any chance? Thats stopping me from digging in more.
>
> (I see the equivalent TraverseStmt() method now, but I do not see a 
> way to get statements fron the ASTContext.)

What you need to do is start the traversing in the HandleTranslationUnit 
method. So long as you keep returning true in the methods you implement, 
you will visit every node. (Side note: there's no way to disable 
visiting particular subtrees, as far as I can see...)

-- 
Joshua Cranmer
News submodule owner
DXR coauthor





More information about the cfe-dev mailing list