<div dir="ltr">Hi Guy, clang used to have xml printer long time ago but it was removed as it lacked in many ways. This came up a few times and I think the community is not opposed to having this functionality, if done right. This is in case you're interested in contributing your changes back to clang. If not you can just hack away on your working copy.<div>
<br></div><div>Others might have better ideas, but you can search the mailing list for xml schema related discussion</div><div><br></div><div>Nikola.</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Sun, Jun 29, 2014 at 7:17 PM, Guy Sherman <span dir="ltr"><<a href="mailto:guy@guysherman.com" target="_blank">guy@guysherman.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word">Hi There,<div><br></div><div>I’m new to this list and new to mucking around with compilers, so I crave your indulgence.</div>
<div><br></div><div>There is a suite of tools called Moose Tools (<a href="http://www.moosetechnology.org/" target="_blank">http://www.moosetechnology.org/</a>), which is somewhat like a Business Intelligence platform for codebases. You convert a codebase to a model of that codebase, and then you can build queries on top of that mode, and visualisations on top of those queries. The models are called an “MSE” file, and they seem similar to an AST. </div>
<div><br></div><div>So anyway, there are reasonably good tools to import codebases from java, smalltalk, etc, but nothing that I’ve tried for C/C++ seems to do the job. So, I did a little bit of reading about Clang and LLVM, and have been wanting to try using the Clang front-end but instead of spitting out LLVM IR I want to generate an MSE file. I had a look at the output from the AST-dump mode of Clang and it looks like the data would be suitable, I could probably write a python script to parse that output and convert it, but I would rather do it properly.</div>
<div><br></div><div>I’m not sure of the right approach though… I could start hacking on the AST-dump mode, but I imagine that this is not something that you would ever want to keep in the CFE codebase. So, is there some guidance somewhere, on putting together the minimal subset of the CFE that I would need in order to be able to dump the AST? Or should I just fork CFE and start from there?</div>
<div><br></div><div><br></div><div>Many thanks,</div><div><br></div><div><br></div><div>Guy Sherman.</div></div><br>_______________________________________________<br>
cfe-dev mailing list<br>
<a href="mailto:cfe-dev@cs.uiuc.edu">cfe-dev@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev</a><br>
<br></blockquote></div><br></div>