[cfe-dev] Getting past error: member access into incomplete type
james.dennett at gmail.com
Sat Sep 1 23:04:30 PDT 2012
On Sat, Sep 1, 2012 at 6:14 PM, Eric Schulte <eric.schulte at gmx.com> wrote:
> I'm working on a small AST-manipulation tool built upon clang . I
> had an implementation which worked but didn't deal well with included
> headings. I've since re-written this using the Tooling interface,
> however using the example code from  I run into the following "member
> access into incomplete type" error on an ASTContext .
> It looks like I could solve this error by stepping back to previous
> versions of clang and llvm , but I'd prefer to fix this so that it
> works with the current code and moving forward. The broken file is at,
> Any suggestions would be greatly appreciated.
If I'm reading this correctly, your code just needs to #include the
definition of the ASTContext class (from
include/clang/AST/ASTContext.h) in order to refer to a member of
ASTContext (e.g., "Context.getTranslationUnitDecl()").
More information about the cfe-dev