diff --git a/.clang-tidy b/.clang-tidy index e96c20ed6..b0f8a5934 100644 --- a/.clang-tidy +++ b/.clang-tidy @@ -59,7 +59,6 @@ Checks: > -portability-std-allocator-const, -readability-avoid-const-params-in-decls, -readability-braces-around-statements, - -readability-const-return-type, -readability-container-data-pointer, -readability-function-cognitive-complexity, -readability-function-size, diff --git a/clang-tidy.md b/clang-tidy.md index 1b9c0aef1..a1abd9a5f 100644 --- a/clang-tidy.md +++ b/clang-tidy.md @@ -118,7 +118,6 @@ Also reports a false positive about templates which deduce the array length: htt We run this separately via `clang-include-cleaner` in the `iwyu.yml` workflow as the findings of the include checkers still need to be reviewed manually before applying them. `bugprone-branch-clone`
-`readability-const-return-type`
`modernize-return-braced-init-list`
`misc-throw-by-value-catch-by-reference`
`readability-avoid-const-params-in-decls`
diff --git a/gui/test/translationhandler/testtranslationhandler.cpp b/gui/test/translationhandler/testtranslationhandler.cpp index f6a925c6b..7abb1c8f7 100644 --- a/gui/test/translationhandler/testtranslationhandler.cpp +++ b/gui/test/translationhandler/testtranslationhandler.cpp @@ -24,7 +24,7 @@ #include #include -static const QStringList getTranslationNames(const TranslationHandler& handler) +static QStringList getTranslationNames(const TranslationHandler& handler) { QStringList names; for (const TranslationInfo& translation : handler.getTranslations()) { diff --git a/lib/standards.h b/lib/standards.h index f22cd7632..619ce6235 100644 --- a/lib/standards.h +++ b/lib/standards.h @@ -59,7 +59,7 @@ struct Standards { } return false; } - const std::string getC() const { + std::string getC() const { switch (c) { case C89: return "c89"; diff --git a/lib/utils.h b/lib/utils.h index d5721574a..9d11a68e9 100644 --- a/lib/utils.h +++ b/lib/utils.h @@ -36,6 +36,7 @@ struct SelectMapKeys { template + // NOLINTNEXTLINE(readability-const-return-type) - false positive typename Pair::first_type operator()(const Pair& p) const { return p.first; }