<div dir="ltr">If the main points you disagree with are variable naming conventions (which clang-format makes no attempt to address), then is it worth discussing a transition towards full-compliance with LLVM style *except* with regards to variable naming conventions?</div>
<div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Aug 20, 2014 at 9:50 AM, Greg Clayton <span dir="ltr"><<a href="mailto:gclayton@apple.com" target="_blank">gclayton@apple.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
My biggest issues with the LLVM coding style are:<br>
- no easy way to identify class instance variables. I would prefer to see "m_" or at least "_" as a prefix for all instance variables.<br>
<br>
An example that stops us from being able to enable the warning for hidden local variables comes from iterator_range.h:<br>
<br>
  iterator_range(IteratorT begin_iterator, IteratorT end_iterator)<br>
      : begin_iterator(std::move(begin_iterator)),<br>
        end_iterator(std::move(end_iterator)) {}<br>
<br>
<br>
And another:<br>
<br>
    DiagStatePoint(DiagState *State, FullSourceLoc Loc)<br>
      : State(State), Loc(Loc) { }<br>
<br>
The name of the ivars match the argument names.<br>
<br>
- I would prefer type names formatted in a specific way (LLDB uses camel case) and variables in another way (LLDB uses lower case separated by '_'). Without this types, variables, and instance variables all look the same.<br>

<div class="HOEnZb"><div class="h5"><br>
<br>
<br>
> On Aug 19, 2014, at 10:35 PM, Chandler Carruth <<a href="mailto:chandlerc@google.com">chandlerc@google.com</a>> wrote:<br>
><br>
><br>
> On Tue, Aug 19, 2014 at 5:03 PM, Chris Lattner <<a href="mailto:clattner@apple.com">clattner@apple.com</a>> wrote:<br>
> On Aug 19, 2014, at 10:16 AM, Zachary Turner <<a href="mailto:zturner@google.com">zturner@google.com</a>> wrote:<br>
><br>
> > I brought this up in a thread on lldb-commits, but since it is of more general interest, I want to make a thread here as well.<br>
> ><br>
> > Can we have clear direction on LLDB coding style?<br>
><br>
> Just to toss out a controversial opinion here, I consider it a bug that LLDB doesn’t follow the documented LLVM coding standard.  This only drives a wedge between LLDB and the rest of the LLVM community.<br>
><br>
> I want to strongly, emphatically agree.<br>
><br>
> Coding standards are most valuable when consistent across a broad, shared body of code. We need more contributors in LLDB, and one place to get them is from the existing large pool of LLVM developers. We should be lowering the barriers there, especially for easy things like coding standards.<br>

><br>
> Also, as we are actively developing convention, standard, and formatting tools, the cost of changing this is going down and the value to the *existing* developers of using the common coding standard is going up.<br>

</div></div><div class="HOEnZb"><div class="h5">> _______________________________________________<br>
> lldb-dev mailing list<br>
> <a href="mailto:lldb-dev@cs.uiuc.edu">lldb-dev@cs.uiuc.edu</a><br>
> <a href="http://lists.cs.uiuc.edu/mailman/listinfo/lldb-dev" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/lldb-dev</a><br>
<br>
<br>
_______________________________________________<br>
lldb-dev mailing list<br>
<a href="mailto:lldb-dev@cs.uiuc.edu">lldb-dev@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/lldb-dev" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/lldb-dev</a><br>
</div></div></blockquote></div><br></div>