[PATCH] D26943: [CodingStandards] Add style guide rule about "if" statements and loops.

Mehdi AMINI via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 23 19:42:27 PST 2016


mehdi_amini added a comment.

In https://reviews.llvm.org/D26943#605046, @kparzysz wrote:

> In https://reviews.llvm.org/D26943#604951, @mehdi_amini wrote:
>
> > Not only, this is part of the "consistency" you mentioned in your second sentence.
>
>
> I meant consistency with the surrounding code---that is much less subjective.


Then I have a strong disagreement on this:

1. clang-format totally changed the way I deal with formatting, and having rules that can be taught to an automatic tool removes any subjectivity and discussion about the formatting.
2. What makes the code "clear" and "readable" beyond the various tastes of contributors, *is* consistency across the codebase. Less brain power used to adapt to different styles is a non-negligible productivity gain to me.


https://reviews.llvm.org/D26943





More information about the llvm-commits mailing list