Extended Description
'clang-diagnostic-' checks family cannot be the only one enabled for running clang-tidy due to 'no checks enabled' error:
$ clang-tidy -checks='-*,clang-diagnostic-unused-variable' main.cpp
Error: no checks enabled.
Extending check list by any other works fine for 'clang-diagnostic-' also:
$ clang-tidy -checks='-*,cert-err34-c,clang-diagnostic-unused-variable'
main.cpp
1 error generated.
What's worse, 'clang-diagnostic-' checks are not printed by listing all available checks:
$ clang-tidy -checks='*' -list-checks | grep clang-diagnostic | wc -l
0
This is really counter-intuitive and makes the user doubt, whether 'clang-diagnostic' checks does still exist.
I've tested that on clang-tidy-5.0.
There is a sample project attached to easily recreate the issue, with clang-tidy calls prepared.
Extended Description
'clang-diagnostic-' checks family cannot be the only one enabled for running clang-tidy due to 'no checks enabled' error:
$ clang-tidy -checks='-*,clang-diagnostic-unused-variable' main.cpp
Error: no checks enabled.
Extending check list by any other works fine for 'clang-diagnostic-' also:
$ clang-tidy -checks='-*,cert-err34-c,clang-diagnostic-unused-variable'
main.cpp
1 error generated.
What's worse, 'clang-diagnostic-' checks are not printed by listing all available checks:
$ clang-tidy -checks='*' -list-checks | grep clang-diagnostic | wc -l
0
This is really counter-intuitive and makes the user doubt, whether 'clang-diagnostic' checks does still exist.
I've tested that on clang-tidy-5.0.
There is a sample project attached to easily recreate the issue, with clang-tidy calls prepared.