<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Thu, Jan 2, 2014 at 11:37 AM, Alp Toker <span dir="ltr"><<a href="mailto:alp@nuanti.com" target="_blank">alp@nuanti.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
On 02/01/2014 10:24, Manuel Klimek wrote:<div class="im"><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On Thu, Jan 2, 2014 at 11:21 AM, Alp Toker <<a href="mailto:alp@nuanti.com" target="_blank">alp@nuanti.com</a> <mailto:<a href="mailto:alp@nuanti.com" target="_blank">alp@nuanti.com</a>>> wrote:<br>
<br>
Just saw this after Manuel replied.<br>
<br>
Is it OK to reformat IWYU pragmas in other coding styles, say in<br>
the LLVM style?<br>
<br>
<br>
I think we mainly want to not have *all* pragmas in *all* coding styles. IWYU is just an example, and we can easily add it to other styles.<br>
<br>
If not, that's an indication this kind of setting should be<br>
separated from individual coding style descriptions as it appears<br>
equally applicable to WebKit, Chromium, LLVM and custom styles.<br>
<br>
<br>
Well, you can set it for all of those? What is your proposed solution?<br>
</blockquote>
<br></div>
A quick fix without major surgery on the proposed patch would be to have the same default value, or empty default value, shared between all built-in coding styles so that switching between them doesn't change behaviour.<br>
<br>
This makes sense because non-reformatted comment pragmas are project-level / user-level settings not related to or really defined by any coding style.<br>
<br>
This'll be great for lit RUN lines too(!)<br></blockquote><div><br></div><div>And for CHECK.*: lines as well (i'll update the patch). But this is a good example of why it doesn't make sense to make this a global setting. I can easily imagine comments starting with " RUN: " or " CHECK: ", that don't have special meaning in any code, that is not lit tests. And then it would be undesirable to leave these comments on a single line, if they exceed column limit.</div>
<div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Alp.<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">
<br>
Cheers,<br>
/Manuel<br>
<br>
<br>
It seems prudent not to add a public config setting with a<br>
commitment of stability until that's addressed or it'll be hard to<br>
fix after the fact.<br>
<br>
Alp.<br>
<br>
<br>
On 02/01/2014 09:58, Manuel Klimek wrote:<br>
<br>
lg<br>
<br>
<br>
================<br>
Comment at: unittests/Format/FormatTest.<u></u>cpp:1053<br>
@@ +1052,3 @@<br>
+ "// IWYU pragma: aaaaaaaaaaaaaaaaaa bbbbbbbbbbbbbb",<br>
+ format("// IWYU pragma: aaaaaaaaaaaaaaaaaa<br>
bbbbbbbbbbbbbb", Pragmas));<br>
+}<br>
----------------<br>
Please add a short test for block comments.<br>
<br>
<br>
<a href="http://llvm-reviews.chandlerc.com/D2460" target="_blank">http://llvm-reviews.chandlerc.<u></u>com/D2460</a><br>
<br>
BRANCH<br>
svn<br>
<br>
ARCANIST PROJECT<br>
clang<br>
______________________________<u></u>_________________<br>
cfe-commits mailing list<br></div>
<a href="mailto:cfe-commits@cs.uiuc.edu" target="_blank">cfe-commits@cs.uiuc.edu</a> <mailto:<a href="mailto:cfe-commits@cs.uiuc.edu" target="_blank">cfe-commits@cs.uiuc.<u></u>edu</a>><div class="im"><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits" target="_blank">http://lists.cs.uiuc.edu/<u></u>mailman/listinfo/cfe-commits</a><br>
<br>
<br>
-- <a href="http://www.nuanti.com" target="_blank">http://www.nuanti.com</a><br>
the browser experts<br>
<br>
<br>
</div></blockquote><div class="HOEnZb"><div class="h5">
<br>
-- <br>
<a href="http://www.nuanti.com" target="_blank">http://www.nuanti.com</a><br>
the browser experts<br></div></div></blockquote></div>
</div></div>