Reputation: 7339
I agree with the majority of the clang-tidy
checks, but some I don't see tremendous value in. Mostly these are the fuschia*
checks, such as the default argument warnings:
error: calling a function that uses a default argument is disallowed [fuchsia-default-arguments...
Therefore I would like to know how to run all of the checks except the fuschia
ones. Right now, I just check everything in Cmake:
set(CMAKE_CXX_CLANG_TIDY
clang-tidy;
-header-filter=.;
-checks=*;
-warnings-as-errors=*;)
Upvotes: 1
Views: 738
Reputation: 2663
Clang-tidy allows you to use positive and negative globs in specifying checks. Just use -
as a prefix when specifying checks you want to exclude. In your case:
-checks=*,-fuchsia*;
If you want to verify which checks are enabled you can run a command:
$ clang-tidy -checks=*,-fuchsia* -list-checks
Upvotes: 4