abacus-develop
abacus-develop copied to clipboard
clang-format and clang-tidy is not employed
Describe the Code Quality Issue
clang-format can format c++ source files; clang-tidy is used to perform static analysis, helping improve code quality.
Adding CI checks utilizing the existed .clang-tidy and .clang-format in the repo on the new-coming PRs would be better.
Some third-party add-ons like https://pre-commit.ci/ is also helpful.
Additional Context
No response
Task list for Issue attackers (only for developers)
- [ ] Identify the specific code file or section with the code quality issue.
- [ ] Investigate the issue and determine the root cause.
- [ ] Research best practices and potential solutions for the identified issue.
- [ ] Refactor the code to improve code quality, following the suggested solution.
- [ ] Ensure the refactored code adheres to the project's coding standards.
- [ ] Test the refactored code to ensure it functions as expected.
- [ ] Update any relevant documentation, if necessary.
- [ ] Submit a pull request with the refactored code and a description of the changes made.
Todo:
- [x] Apply fixes to codes. Please preview the changes at this branch.
- [ ] Format all codes.
- [ ] Set up CI pipelines to prettify codes on PRs, not requiring extra works for developers.
- possible choices: https://pre-commit.ci, https://trunk.io/check/clang-tidy
@mohanchen thinks this function is very important for ABACUS. So, we need a meeting to discuss.