feat(tidy): add fairmq-modernize-channels-access

- Report uses of the deprecated member fair::mq::Device::fChannels.
- Replace fChannels.at(name).at(index) with GetChannel(name, index) and
  every other use with GetChannels().
- Ignore uses inside fair::mq::Device itself.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Claude
2026-11-09 22:39:03 +00:00
parent d4a3c06c7b
commit 84ac7aecfd
5 changed files with 176 additions and 0 deletions

View File

@@ -6,6 +6,7 @@
* copied verbatim in the file "LICENSE" *
********************************************************************************/
#include <fairmq/tidy/ChannelsAccessCheck.h>
#include <fairmq/tidy/DeprecatedHeadersCheck.h>
#include <fairmq/tidy/NonNamespacedTypesCheck.h>
@@ -21,6 +22,7 @@ class Module : public clang::tidy::ClangTidyModule
public:
void addCheckFactories(clang::tidy::ClangTidyCheckFactories& factories) override
{
factories.registerCheck<ChannelsAccessCheck>("fairmq-modernize-channels-access");
factories.registerCheck<DeprecatedHeadersCheck>("fairmq-modernize-deprecated-headers");
factories.registerCheck<NonNamespacedTypesCheck>("fairmq-modernize-nonnamespaced-types");
}