conform to clang-tidy checks
mabraham opened this issue · 0 comments
Currently optional-lite emits many warnings with useful checkers enabled in clang-tidy. Adoption of optional-lite in code bases also using clang-tidy is currently inconvenient because clang-tidy has no way of unilaterally suppressing warnings from the content of the header (although it can do a source file).
As we intend to adopt optional-lite in https://github.com/gromacs/gromacs, we have suppressed many of these, e.g. https://gerrit.gromacs.org/c/gromacs/+/9273/9/src/gromacs/compat/optional.h#207. However we'd like to contribute the improvements so others can benefit, and minimize our cost of upgrading to any future versions.
Is there interest in accepting contributed changes to address such warnings?
Some like https://gerrit.gromacs.org/c/gromacs/+/9273/9/src/gromacs/compat/optional.h#1321 are probably best fixed by e.g. introducing the suggested parentheses, which avoids the noisy NOLINT and NOLINTNEXTLINE comments.
Some warnings might not be worth the cost of suppression/fixing, and we'll happily handle those in our bundled version.