[cfe-dev] Deleting Variable on the AST - Was: Future of AST transformation
Maximilian Odendahl
maxodendahl at gmail.com
Mon Jul 23 23:50:16 PDT 2012
Hi,
> The way to deal with this is to perform your transformation from the
>ASTConsumer::HandleTranslationUnit callback. At that point, the entire
>AST has been formed, but the Sema object is still alive and ready to
>do stuff.
I am jumping in here, as I am trying to do this exactly. I would now
like to delete a global variable on the AST(to which I have a VarDecl)
so it is gone when printing the AST later on. I understand it is not
really a transformation, but any easy way to do this?
Best,
Max
More information about the cfe-dev
mailing list