limenka-tidy.cpp raw
1 // Copyright (c) 2023 Limenka Developers
2 // Distributed under the MIT software license, see the accompanying
3 // file COPYING or http://www.opensource.org/licenses/mit-license.php.
4
5 #include "nontrivial-threadlocal.h"
6
7 #include <clang-tidy/ClangTidyModule.h>
8 #include <clang-tidy/ClangTidyModuleRegistry.h>
9
10 class LimenkaModule final : public clang::tidy::ClangTidyModule
11 {
12 public:
13 void addCheckFactories(clang::tidy::ClangTidyCheckFactories& CheckFactories) override
14 {
15 CheckFactories.registerCheck<limenka::NonTrivialThreadLocal>("limenka-nontrivial-threadlocal");
16 }
17 };
18
19 static clang::tidy::ClangTidyModuleRegistry::Add<LimenkaModule>
20 X("limenka-module", "Adds limenka checks.");
21
22 volatile int LimenkaModuleAnchorSource = 0;
23