[llvm] [RFC][Docs] Clarify brace omission for single-line bodies (PR #195985)

Erich Keane via llvm-commits llvm-commits at lists.llvm.org
Thu May 7 06:18:29 PDT 2026


erichkeane wrote:

> > the definition of that is a mixture of author and reviewer opinions (weighing reviewers more heavily obviously).
> 
> It's not obvious to me why reviewers are weighed more heavily. If that is the case, then for the exact same piece of code, exchanging the reviewer and the author will produce a different result. What is that automatically makes the author's opinion weaker than a reviewer, as if the former were a supplicant looking for approval?

Because it is about READABILITY.  And so the person reading the code is the one who is experiencing the code as a reader.  So a 'writer' of the code is probably the worst one to make the determination.  I've had plenty of times where I've reviewed something (prose in particular) where the writer would respond, "oh, I didn't realize it was ambiguous/hard to read/etc until you said that!".


https://github.com/llvm/llvm-project/pull/195985


More information about the llvm-commits mailing list