summaryrefslogtreecommitdiffstats
path: root/clang-tools-extra/clang-tidy/readability/ReadabilityTidyModule.cpp
diff options
context:
space:
mode:
authorAlexander Kornienko <alexfh@google.com>2016-03-30 11:31:33 +0000
committerAlexander Kornienko <alexfh@google.com>2016-03-30 11:31:33 +0000
commite3ae0c6f19fd53db0b5e79e264585109b0d3768b (patch)
tree95eae7edc1b075f30bd29ab017f1c23aa59792e1 /clang-tools-extra/clang-tidy/readability/ReadabilityTidyModule.cpp
parent1b654f2293f7859676edc6b06156de84c32f482a (diff)
downloadbcm5719-llvm-e3ae0c6f19fd53db0b5e79e264585109b0d3768b.tar.gz
bcm5719-llvm-e3ae0c6f19fd53db0b5e79e264585109b0d3768b.zip
[clang-tidy] readability check for const params in declarations
Summary: Adds a clang-tidy warning for top-level consts in function declarations. Reviewers: hokein, sbenza, alexfh Subscribers: cfe-commits Patch by Matt Kulukundis! Differential Revision: http://reviews.llvm.org/D18408 llvm-svn: 264856
Diffstat (limited to 'clang-tools-extra/clang-tidy/readability/ReadabilityTidyModule.cpp')
-rw-r--r--clang-tools-extra/clang-tidy/readability/ReadabilityTidyModule.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/clang-tools-extra/clang-tidy/readability/ReadabilityTidyModule.cpp b/clang-tools-extra/clang-tidy/readability/ReadabilityTidyModule.cpp
index 5803f5f0997..00366c8cc64 100644
--- a/clang-tools-extra/clang-tidy/readability/ReadabilityTidyModule.cpp
+++ b/clang-tools-extra/clang-tidy/readability/ReadabilityTidyModule.cpp
@@ -10,6 +10,7 @@
#include "../ClangTidy.h"
#include "../ClangTidyModule.h"
#include "../ClangTidyModuleRegistry.h"
+#include "AvoidConstParamsInDecls.h"
#include "BracesAroundStatementsCheck.h"
#include "ContainerSizeEmptyCheck.h"
#include "ElseAfterReturnCheck.h"
@@ -32,6 +33,8 @@ namespace readability {
class ReadabilityModule : public ClangTidyModule {
public:
void addCheckFactories(ClangTidyCheckFactories &CheckFactories) override {
+ CheckFactories.registerCheck<AvoidConstParamsInDecls>(
+ "readability-avoid-const-params-in-decls");
CheckFactories.registerCheck<BracesAroundStatementsCheck>(
"readability-braces-around-statements");
CheckFactories.registerCheck<ContainerSizeEmptyCheck>(
OpenPOWER on IntegriCloud