[cfe-dev] How to get symbol's info. when the symbol is in macro instantiation
dgregor at apple.com
Tue Jan 25 07:53:18 PST 2011
On Jan 25, 2011, at 12:30 AM, jiyang zhao wrote:
> Hi list
> I meet a problem about macro when using libclang, when i want to get a viriable's infomation which is in a macro instantiation, for example, its linkage kind, i get 200(UnexposedStmt), is this the expected result? If so, how can i get the exact information of the symbol(e.g. previous in following code, SETARG_B is macro)?
> SETARG_B(*previous, from+n-1);
This reference to previous will show up as a CXCursor_DeclRefExpr cursor. You can then use clang_getCursorReferenced() to find the declaration that the cursor points to.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the cfe-dev