[cfe-dev] "Run 3.3 based source to source rewriter with 3.1 based Clang"
welson.sun at gmail.com
Sat Jan 4 13:20:04 PST 2014
Basically I need a source to source rewriter. Since LibTooling is available
since v3.3, so the program has to be compiled and linked with v3.3
For some reason, I have to use the v3.1 Clang as the frontend of the
The intended flow is that: The v3.1 based Clang is used to compile the
source code, annotating the FunctionDecl node based on some in-house pragma
handling, the rewriter checks the annotation and do the rewrite accordingly.
The current problem is that the VisitDecl(Decl* d) function cannot find that
FunctionDecl's annotation, although if I run the Clang itself, I have added
code in codegen to verify that the FunctionDecl has been properly annotated.
I am wondering if this kind of mixing of Clang frontend version (3.1) with
source rewriter version (3.3) is supposed to work. Well, my another source
to source rewriter tool uses the same version mix and works fine, but that
one doesn't rely on extra annotation of the FunctionDecl node.
View this message in context: http://clang-developers.42468.n3.nabble.com/Run-3-3-based-source-to-source-rewriter-with-3-1-based-Clang-tp4036896.html
Sent from the Clang Developers mailing list archive at Nabble.com.
More information about the cfe-dev