[cfe-dev] Building AST at runtime

Sean Silva silvas at purdue.edu
Fri Jul 12 18:20:59 PDT 2013


On Fri, Jul 12, 2013 at 4:09 PM, Daniel Albuschat <d.albuschat at gmail.com>wrote:

>
> P.S.: Yes, I have been recommended to create C++ code instead of trying to
> build an AST. But I'd still like to try the AST approach, since I'd like to
> skip the (time consuming) parsing of the C++ code.
>
>
Clang's AST is really complicated and there are a number of undocumented
invariants, so trying to build the AST "raw" is really difficult (I've
never heard of anybody doing it successfully). If you really want to go
this route, looking at lib/Sema/TreeTransform.h is probably your best guide.

-- Sean Silva
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20130712/64796fb2/attachment.html>


More information about the cfe-dev mailing list