-
Notifications
You must be signed in to change notification settings - Fork 197
Use clang-format for C++ code #2643
Copy link
Copy link
Closed
Description
I would like to suggest to use clang-format to format our C++ code. This will provide consistency and make the formatting of our C++ code uniform for all developers. We can enforce this by a simple CI check that ensures that new codes adhere to our chosen style. clang-format is available on all platforms and is supported by all major IDEs.
As for what formatting style we should use, clang-format provides 6 default styles: LLVM, Google, Chromium, Mozilla, WebKit or Microsoft. We should just pick one and stick with it (you can experiment with the different styles and options here). If we want to customise specific formatting rules we can, but we should try to stick with one of the defaults.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels