summaryrefslogtreecommitdiffstats
path: root/clang-tools-extra/clang-tidy/cppcoreguidelines
diff options
context:
space:
mode:
Diffstat (limited to 'clang-tools-extra/clang-tidy/cppcoreguidelines')
-rw-r--r--clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeConstCastCheck.cpp3
-rw-r--r--clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeConstCastCheck.h1
-rw-r--r--clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeReinterpretCastCheck.cpp8
-rw-r--r--clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeReinterpretCastCheck.h2
4 files changed, 6 insertions, 8 deletions
diff --git a/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeConstCastCheck.cpp b/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeConstCastCheck.cpp
index 37aa04e605b..6b32ad04a3f 100644
--- a/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeConstCastCheck.cpp
+++ b/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeConstCastCheck.cpp
@@ -17,7 +17,7 @@ namespace clang {
namespace tidy {
void ProTypeConstCastCheck::registerMatchers(MatchFinder *Finder) {
- if(!getLangOpts().CPlusPlus)
+ if (!getLangOpts().CPlusPlus)
return;
Finder->addMatcher(cxxConstCastExpr().bind("cast"), this);
@@ -30,4 +30,3 @@ void ProTypeConstCastCheck::check(const MatchFinder::MatchResult &Result) {
} // namespace tidy
} // namespace clang
-
diff --git a/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeConstCastCheck.h b/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeConstCastCheck.h
index 1515797acc1..af7c5547c23 100644
--- a/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeConstCastCheck.h
+++ b/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeConstCastCheck.h
@@ -31,4 +31,3 @@ public:
} // namespace clang
#endif // LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_CPPCOREGUIDELINES_PRO_TYPE_CONST_CAST_H
-
diff --git a/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeReinterpretCastCheck.cpp b/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeReinterpretCastCheck.cpp
index db858836f58..57c4a59b8f6 100644
--- a/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeReinterpretCastCheck.cpp
+++ b/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeReinterpretCastCheck.cpp
@@ -1,4 +1,4 @@
-//===--- ProTypeReinterpretCastCheck.cpp - clang-tidy--------------------------===//
+//===--- ProTypeReinterpretCastCheck.cpp - clang-tidy----------------------===//
//
// The LLVM Compiler Infrastructure
//
@@ -23,11 +23,11 @@ void ProTypeReinterpretCastCheck::registerMatchers(MatchFinder *Finder) {
Finder->addMatcher(cxxReinterpretCastExpr().bind("cast"), this);
}
-void ProTypeReinterpretCastCheck::check(const MatchFinder::MatchResult &Result) {
+void ProTypeReinterpretCastCheck::check(
+ const MatchFinder::MatchResult &Result) {
const auto *MatchedCast =
Result.Nodes.getNodeAs<CXXReinterpretCastExpr>("cast");
- diag(MatchedCast->getOperatorLoc(),
- "do not use reinterpret_cast");
+ diag(MatchedCast->getOperatorLoc(), "do not use reinterpret_cast");
}
} // namespace tidy
diff --git a/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeReinterpretCastCheck.h b/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeReinterpretCastCheck.h
index e59fcf99018..0ca16e54112 100644
--- a/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeReinterpretCastCheck.h
+++ b/clang-tools-extra/clang-tidy/cppcoreguidelines/ProTypeReinterpretCastCheck.h
@@ -18,7 +18,7 @@ namespace tidy {
/// Flags all occurrences of reinterpret_cast
///
/// For the user-facing documentation see:
-/// http://clang.llvm.org/extra/clang-tidy/checks/misc-no-reinterpret-cast.html
+/// http://clang.llvm.org/extra/clang-tidy/checks/cppcoreguidelines-pro-type-reinterpret-cast.html
class ProTypeReinterpretCastCheck : public ClangTidyCheck {
public:
ProTypeReinterpretCastCheck(StringRef Name, ClangTidyContext *Context)
OpenPOWER on IntegriCloud