[PATCH] D33531: Clang-tidy readability: avoid const value return
Alexander Kornienko via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon May 29 06:49:31 PDT 2017
alexfh added a comment.
> Would it make sense to silence this diagnostic in the presence of also checking for cert-dcl21-cpp for such operators?
Currently there's no mechanism in clang-tidy to express dependencies or compatibility issues between checks. Moreover, we already have checks that are not meant to be run together, for example, readability-braces-around-statements and its google- incarnation (and other alias checks with different settings). That said, we could whitelist postfix increment and decrement operators in this check. Camillo, WDYT?
On a side note, the check's performance implications might be more important than the readability aspect of dropping the `const`, so the check might be a better fit for the `performance` category.
Repository:
rL LLVM
https://reviews.llvm.org/D33531
More information about the cfe-commits
mailing list