<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<p><br>
</p>
<p>If you go with a clang-tidy check (seems appropriate) you would
need to write AST Matchers to find the places in code to
transform, and then make transformations at the appropriate source
locations.</p>
<p>This gives you a start in the former:
<a class="moz-txt-link-freetext" href="http://ce.steveire.com/z/d3njX8">http://ce.steveire.com/z/d3njX8</a></p>
<p>and <a class="moz-txt-link-freetext" href="http://ce.steveire.com/z/qJd39w">http://ce.steveire.com/z/qJd39w</a> with the latter and see</p>
<p> <a class="moz-txt-link-freetext" href="https://steveire.wordpress.com/2019/04/30/the-future-of-ast-matching-refactoring-tools-eurollvm-and-accu/">https://steveire.wordpress.com/2019/04/30/the-future-of-ast-matching-refactoring-tools-eurollvm-and-accu/</a></p>
<p>for more.</p>
<p>Thanks,</p>
<p>Stephen<br>
</p>
<p><br>
</p>
<div class="moz-cite-prefix">On 12/06/2020 02:30, Ray Zhang via
cfe-dev wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CAEv7QpyVA0y4tekMhNNuNNOSejA4etS-N77vPwGEOG09MJQ2og@mail.gmail.com">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<div dir="ltr">
<div>Hi cfe-dev,</div>
<div><br>
</div>
<div>I've been playing around with clang's frontend and I really
appreciate how well documented and noob-friendly it is in
order to develop tooling for C++. I see in <a
href="https://clang.llvm.org/docs/ClangTools.html"
moz-do-not-send="true">this page</a> that one of the ideas
for new tools is to refactor C-style casts to the appropriate
C++ style cast. I'm interested in working on it but I'm not
sure where I should contribute it to. I see in <font
face="monospace">clang-tools-extra</font><font face="arial,
sans-serif"> that there are two ways of adding features, and
that is to add the project at the top-level as something
like </font><font face="monospace">clang-refactor-casts</font><font
face="arial, sans-serif">, or to contribute to </font><font
face="monospace">clang-tidy</font><font face="arial,
sans-serif">, particularly the </font><font
face="monospace">modernize</font><font face="arial,
sans-serif"> subdirectory which the change for this also
fits appropriately in. </font><br>
</div>
<div><font face="arial, sans-serif"><br>
</font></div>
<div><font face="arial, sans-serif">Is there some documentation
somewhere that outlines where new contributions for projects
of this type should go to? I'd love to help in any way I can
:)</font></div>
<div><font face="arial, sans-serif"><br>
</font></div>
<div><span style="font-family:arial,sans-serif">- Ray</span><br>
</div>
<div><br>
</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<pre class="moz-quote-pre" wrap="">_______________________________________________
cfe-dev mailing list
<a class="moz-txt-link-abbreviated" href="mailto:cfe-dev@lists.llvm.org">cfe-dev@lists.llvm.org</a>
<a class="moz-txt-link-freetext" href="https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev">https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev</a>
</pre>
</blockquote>
</body>
</html>