[cfe-dev] Source-to-source manipulations with Clang

Andrey Tarasevich tarasevich.andrey at googlemail.com
Thu Jan 27 04:52:01 PST 2011


Hello!

Recently I started using Clang for the C-code parsing, but I have some
problems with find information on how to do Source-to-source
transformations.

At the moment I can generate Abstract Syntax Tree and tree traversal trough
the API, i.e. rewriting the ASTConsumer and DeclVisitor classes, but I don't
know how to do the transformations of the AST and write it back to the
source code. Could you please give me some feedback on how to do such
manipulations? I didn't find anything useful in google, so I decided to
write to mailing list.

I hope I was clear enough
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20110127/5c13e5f3/attachment.html>


More information about the cfe-dev mailing list