<br><br><div>On Sun Dec 29 2013 at 10:25:19 AM, Schlottke, Michael <<a href="mailto:m.schlottke@fz-juelich.de">m.schlottke@fz-juelich.de</a>> wrote:</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">




<div>
Hi David, 
<div><br>
</div>
<div>Thanks for the fast reply. </div>
<div><br>
</div>
<div>From your description I infer that clang-fixit is a tool for enforcing a certain naming convention, rather than changing specific names, or did I misunderstand you? </div></div></blockquote><div><br></div><div>That's correct - but it has the same challenges in terms of resizing names, etc.</div>
<div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div>
<div><br>
</div>
<div>However, maybe it could be a place for me to start looking for ideas... The only reference I found to clang-fixit is <a href="http://llvm-reviews.chandlerc.com/D51" target="_blank">http://llvm-reviews.chandlerc.com/D51</a>, but nothing in the llvm or clang/extra repository. Could you tell me where I can find more information
 on it? </div></div></blockquote><div><br></div><div>Hmm, perhaps it hasn't really been started yet. Sorry for the red herring.<br><br>I would guess clang-migrate would be the next best tool to look at. It does various code changes and deals with reformatting the resulting code, etc.</div>
<div><br></div><div>- David</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div>
<div><br>
</div>
<div>Regards, </div>
<div><br>
</div>
<div>Michael </div>
<br>
<br>
<br>
-------- Ursprüngliche Nachricht --------<br>
Von: <a href="mailto:dblaikie@gmail.com" target="_blank">dblaikie@gmail.com</a> <br>
Datum: <br>
An: "Schlottke, Michael" <<a href="mailto:m.schlottke@fz-juelich.de" target="_blank">m.schlottke@fz-juelich.de</a>>,cfe-dev Developers <<a href="mailto:cfe-dev@cs.uiuc.edu" target="_blank">cfe-dev@cs.uiuc.edu</a>>,<a href="mailto:djasper@google.com" target="_blank">djasper@google.com</a>,<a href="mailto:klimek@google.com" target="_blank">klimek@google.com</a>
<br>
Betreff: [cfe-dev] LibTooling vs. LibClang+Python for simple refactoring <br></div><div>
<br>
<br>
<div>Tooling, specifically the clang-fixit till is one place sheet efforts are being made to apply these kinds of refractoriness (specifically clang-fixit would apply predefined naming convention rules, rather than user specified renaming).<br>

<br>
One of the things that tooling might help you with would be the necessary reformatting (clang-format) and build/source discovery.<br>
<p dir="ltr"></p>
<p dir="ltr">On Sunday, December 29, 2013 3:49:06 AM, Schlottke, Michael <<a href="mailto:m.schlottke@fz-juelich.de" target="_blank">m.schlottke@fz-juelich.de</a>> wrote:</p>
<blockquote>
<p dir="ltr">Hi everyone,</p>
<p dir="ltr">For our research group, I need to get started with some relatively simple refactoring tasks in a modestly complex C++ project. The goal is to have a tool that (in the beginning) is good for at least two things:<br>

- renaming member variables/methods<br>
- replacing member variable access by getters/setters</p>
<p dir="ltr">After the extremely positive experiences I've had with clang (and since the IDE tools I tried failed for our project), I'd like to utilize the clang infrastructure for this task. However, in the very beginning I already face the problem of where
 I should start:</p>
<p dir="ltr">On the one hand, LibTooling seems to be the interface of choice when it comes to refactoring code (it's one of the canonical examples on
<a href="http://clang.llvm.org/docs/Tooling.html" target="_blank">http://</a><a href="http://clang.llvm.org/docs/Tooling.html" target="_blank">clang.llvm.org</a><a href="http://clang.llvm.org/docs/Tooling.html" target="_blank">/docs/</a><a href="http://clang.llvm.org/docs/Tooling.html" target="_blank">Tooling.html</a>).
 On the other hand libclang seems to be easier to use, has Python bindings, and from the outset looks like it could be already sufficient for the task at hand.</p>
<p dir="ltr">Do you have any experience/recommendations for which library is the one to use in this case?</p>
<p dir="ltr">Regards,</p>
<p dir="ltr">Michael</p>
<p dir="ltr">--<br>
Michael Schlottke</p>
<p dir="ltr">SimLab Highly Scalable Fluids & Solids Engineering<br>
Jülich Supercomputing Centre (JSC)<br>
Forschungszentrum Jülich GmbH<br>
52425 Jülich<br>
Germany</p>
<p dir="ltr">Phone: +49 (2461) 61 2326<br>
Mail: <a href="mailto:m.schlottke@fz-juelich.de" target="_blank">m.schlottke</a><a href="mailto:m.schlottke@fz-juelich.de" target="_blank">@</a><a href="mailto:m.schlottke@fz-juelich.de" target="_blank">fz</a><a href="mailto:m.schlottke@fz-juelich.de" target="_blank">-</a><a href="mailto:m.schlottke@fz-juelich.de" target="_blank">juelich.de</a><br>

Web: <a href="http://www.fz-juelich.de/jsc" target="_blank">http://</a><a href="http://www.fz-juelich.de/jsc" target="_blank">www.fz</a><a href="http://www.fz-juelich.de/jsc" target="_blank">-</a><a href="http://www.fz-juelich.de/jsc" target="_blank">juelich.de</a><a href="http://www.fz-juelich.de/jsc" target="_blank">/</a><a href="http://www.fz-juelich.de/jsc" target="_blank">jsc</a><br>

<br>
<br>
</p>
<p dir="ltr"><font color="#000000">------------------------------------------------------------------------------------------------</font><br>
<font color="#000000">------------------------------------------------------------------------------------------------</font><br>
<font color="#000000">Forschungszentrum</font><font color="#000000"> </font><font color="#000000">Juelich</font><font color="#000000"> GmbH</font><br>
<font color="#000000">52425 </font><font color="#000000">Juelich</font><br>
<font color="#000000">Sitz </font><font color="#000000">der</font><font color="#000000">
</font><font color="#000000">Gesellschaft</font><font color="#000000">: </font><font color="#000000">Juelich</font><br>
<font color="#000000">Eingetragen</font><font color="#000000"> </font><font color="#000000">im</font><font color="#000000">
</font><font color="#000000">Handelsregister</font><font color="#000000"> </font>
<font color="#000000">des</font><font color="#000000"> </font><font color="#000000">Amtsgerichts</font><font color="#000000">
</font><font color="#000000">Dueren</font><font color="#000000"> </font><font color="#000000">Nr</font><font color="#000000">. HR B 3498</font><br>
<font color="#000000">Vorsitzender</font><font color="#000000"> </font><font color="#000000">des</font><font color="#000000">
</font><font color="#000000">Aufsichtsrats</font><font color="#000000">: </font><font color="#000000">MinDir</font><font color="#000000"> Dr. Karl
</font><font color="#000000">Eugen</font><font color="#000000"> </font><font color="#000000">Huthmacher</font><br>
<font color="#000000">Geschaeftsfuehrung</font><font color="#000000">: Prof. Dr. </font>
<font color="#000000">Achim</font><font color="#000000"> </font><font color="#000000">Bachem</font><font color="#000000"> (</font><font color="#000000">Vorsitzender</font><font color="#000000">),</font><br>
<font color="#000000">Karsten</font><font color="#000000"> </font><font color="#000000">Beneke</font><font color="#000000"> (</font><font color="#000000">stellv</font><font color="#000000">.
</font><font color="#000000">Vorsitzender</font><font color="#000000">), Prof. Dr.-</font><font color="#000000">Ing</font><font color="#000000">. Harald Bolt,</font><br>
<font color="#000000">Prof. Dr. Sebastian M. Schmidt</font><br>
<font color="#000000">------------------------------------------------------------------------------------------------</font><br>
<font color="#000000">------------------------------------------------------------------------------------------------</font><br>
</p>
</blockquote>
<p dir="ltr"><br>
</p>
</div>
</div></blockquote>