blob: fa99f9967f064181bdd443d35d45ebbc635d75c9 [file] [log] [blame]
Benjamin Kramer498cce52014-08-13 13:57:57 +00001//===--- HeaderGuardCheck.h - clang-tidy ------------------------*- C++ -*-===//
2//
3// The LLVM Compiler Infrastructure
4//
5// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
9
10#ifndef LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_LLVM_HEADER_GUARD_CHECK_H
11#define LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_LLVM_HEADER_GUARD_CHECK_H
12
13#include "../utils/HeaderGuard.h"
14
15namespace clang {
16namespace tidy {
17
18/// Finds and fixes header guards that do not adhere to LLVM style.
19class LLVMHeaderGuardCheck : public HeaderGuardCheck {
20public:
21 bool shouldSuggestEndifComment(StringRef Filename) override { return false; }
22 bool shouldFixHeaderGuard(StringRef Filename) override;
23 std::string getHeaderGuard(StringRef Filename, StringRef OldGuard) override;
24};
25
26} // namespace tidy
27} // namespace clang
28
29#endif // LLVM_CLANG_TOOLS_EXTRA_CLANG_TIDY_LLVM_HEADER_GUARD_CHECK_H