Proposal: run clang-format and autopep8 on the existing code base; potentially add pre-commit hook for code style checking
The current C++ code base follows C and fortran coding style, which is a bit stale given that C++14 is used. We would like to clang-format all the C++ code base and run autopep8 on all the python code base to adapt to the latest industry standards and modern C++ coding.
This can be done in v4.1. @pgmpablo157321 FYI. I can help if needed.
As mentioned by Pablo, pre-commit hook is not necessarily installed by the developer. Automatically apply the format change in the PR automation is more reasonable.
Note: if automatic reformat is enabled, clang-format config needs to include SortIncludes: false so the functionality of the original code is not affected.
@pgmpablo157321 to handle
clang-format has many style options and even predefined options (LLVM, Google, Chromium, Mozilla, WebKit, Microsoft). Any thoughts on which one we should adopt?
As a recycled compiler person :), I'd vote for LLVM ;).
Closing this issue.