[PATCH] D151187: [doc] Add casting style preference to coding standards

Aaron Ballman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 15 05:42:26 PDT 2023


aaron.ballman added a comment.

In D151187#4424320 <https://reviews.llvm.org/D151187#4424320>, @mehdi_amini wrote:

> I find the "prefer the prevailing style" mantra unsatisfying in that it does not provide a path forward to evolve the codebase toward a unified style, which seems like an ideal state from a "style guide" point of view.

The thinking is that the path naturally converges as more and more new code gets written using the new style out of habit, and only when the prevailing style makes it incredibly obvious you're doing something different does code stick with the older style. It takes a *long* time to migrate to the new style this way, but it does work (at least in my experience on the Clang side of things).


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D151187/new/

https://reviews.llvm.org/D151187



More information about the llvm-commits mailing list