Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apply a few more clang-tidy checks #1027

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

guitargeek
Copy link
Contributor

Add a few more clang-tidy checks and apply them to the codebase.

The most important check here is modernize-use-default-member-init, because it helps to ensure that we do default member variable initialization. Doing this consistently helps to avoid undefined behavior.

How this was done:

mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=../install -DINSTALL_PYTHON=FALSE -DCMAKE_EXPORT_COMPILE_COMMANDS=ON ..
make -j12
run-clang-tidy -config-file=../.clang-tidy -export-fixes fixes.yaml -header-filter="interface/.*" .
mv fixes.yaml ..
cd ..
clang-apply-replacements .

Add a few more clang-tidy checks and apply them to the codebase.

The most important check here is `modernize-use-default-member-init`,
because it helps to ensure that we do default member variable
initialization. Doing this consistently helps to avoid undefined
behavior.

The changes were *automatically generated by clang-tidy*.

How this was done:

```
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=../install -DINSTALL_PYTHON=FALSE -DCMAKE_EXPORT_COMPILE_COMMANDS=ON ..
make -j12
run-clang-tidy -config-file=../.clang-tidy -export-fixes fixes.yaml -header-filter="interface/.*" .
mv fixes.yaml ..
cd ..
clang-apply-replacements .
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant