[cfe-dev] clang_indexSourceFile and CXCursor_(ParmDecl|VarDecl|DeclRefExpr)

David Mirabito david.mirabito at gmail.com
Fri Jan 13 13:10:44 PST 2012


Hi All,

For the record once I got syntax colouring working (tokenise and attribute the resulting list) I moved on to flagging warnings / errors (a-la XCode). I too was surprised that only some declarations/references were raised to the callback functions - most seemed related to global and cross-translation unit. All the 'internal' stuff was stripped.
Additionally, try as I might I cannot get the 'diagnostic' callback to be triggered, whether I introduce warnings or errors in the parsed code.

At first I thought it was just me or my app doing something stupid :)

I might try migrating to visitChildren and the explicit API calls to get and walk the diagnostic list of a TU.

Cheers,
DavidM

On 13/01/2012, at 3:06 AM, Anders Bakken wrote:
<snip>
> No mention of either the local variable inside foo(int) or the
> parameter. Is this the way it's supposed to be? I've noticed a lot
> work has gone into these new APIs.
> 





More information about the cfe-dev mailing list