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

Partially apply clang-tidy fixes we don't enforce yet #8376

Merged
merged 4 commits into from
Aug 16, 2024

Conversation

abadams
Copy link
Member

@abadams abadams commented Aug 7, 2024

Many of these come from clang-tidy-19, which we don't yet use

  • Put a bunch of stuff into anonymous namespaces
  • Delete some redundant casts (e.g. casting an int to int)
  • Add some const refs to avoid copies
  • Remove meaningless inline qualifiers on in-class definitions and constexpr functions
  • Remove return-with-value from functions returning void
  • Delete a little dead code
  • Use std::min/max where appropriate
  • Don't use a variable after std::forwarding it. It may have been moved from.
  • Use std::string::empty instead of comparing length to zero

- Put a bunch of stuff into anonymous namespaces
- Delete some redundant casts (e.g. casting an int to int)
- Add some const refs to avoid copies
- Remove meaningless inline qualifiers on in-class definitions and
constexpr functions
- Remove return-with-value from functions returning void
- Delete a little dead code
- Use std::min/max where appropriate
- Don't use a variable after std::forwarding it. It may have been moved
from.
- Use std::string::empty instead of comparing length to zero
@steven-johnson
Copy link
Contributor

Ready to land?

@abadams abadams merged commit 4f30d2b into main Aug 16, 2024
19 checks passed
mcourteaux pushed a commit to mcourteaux/Halide that referenced this pull request Sep 15, 2024
* Partially apply clang-tidy fixes we don't use yet

- Put a bunch of stuff into anonymous namespaces
- Delete some redundant casts (e.g. casting an int to int)
- Add some const refs to avoid copies
- Remove meaningless inline qualifiers on in-class definitions and
constexpr functions
- Remove return-with-value from functions returning void
- Delete a little dead code
- Use std::min/max where appropriate
- Don't use a variable after std::forwarding it. It may have been moved
from.
- Use std::string::empty instead of comparing length to zero

* Undo unintentional formatting change

* Restore some necessary casts

* Add NOLINT to silence older clang-tidy
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.

2 participants