diff --git a/clang/lib/Format/AffectedRangeManager.cpp b/clang/lib/Format/AffectedRangeManager.cpp index bf124d73e89e7..ae08965714b1b 100644 --- a/clang/lib/Format/AffectedRangeManager.cpp +++ b/clang/lib/Format/AffectedRangeManager.cpp @@ -13,7 +13,6 @@ #include "AffectedRangeManager.h" -#include "FormatToken.h" #include "TokenAnnotator.h" namespace clang { diff --git a/clang/lib/Format/BreakableToken.cpp b/clang/lib/Format/BreakableToken.cpp index 75304908dc650..c33b74eeb80b4 100644 --- a/clang/lib/Format/BreakableToken.cpp +++ b/clang/lib/Format/BreakableToken.cpp @@ -15,10 +15,6 @@ #include "BreakableToken.h" #include "ContinuationIndenter.h" #include "clang/Basic/CharInfo.h" -#include "clang/Format/Format.h" -#include "llvm/ADT/STLExtras.h" -#include "llvm/Support/Debug.h" -#include #define DEBUG_TYPE "format-token-breaker" diff --git a/clang/lib/Format/ContinuationIndenter.cpp b/clang/lib/Format/ContinuationIndenter.cpp index 964f1ead806bf..3987f2185450e 100644 --- a/clang/lib/Format/ContinuationIndenter.cpp +++ b/clang/lib/Format/ContinuationIndenter.cpp @@ -14,15 +14,6 @@ #include "ContinuationIndenter.h" #include "BreakableToken.h" #include "FormatInternal.h" -#include "FormatToken.h" -#include "WhitespaceManager.h" -#include "clang/Basic/OperatorPrecedence.h" -#include "clang/Basic/SourceManager.h" -#include "clang/Basic/TokenKinds.h" -#include "clang/Format/Format.h" -#include "llvm/ADT/StringSet.h" -#include "llvm/Support/Debug.h" -#include #define DEBUG_TYPE "format-indenter" diff --git a/clang/lib/Format/DefinitionBlockSeparator.cpp b/clang/lib/Format/DefinitionBlockSeparator.cpp index 319236d3bd618..32fc77de4407c 100644 --- a/clang/lib/Format/DefinitionBlockSeparator.cpp +++ b/clang/lib/Format/DefinitionBlockSeparator.cpp @@ -14,7 +14,6 @@ //===----------------------------------------------------------------------===// #include "DefinitionBlockSeparator.h" -#include "llvm/Support/Debug.h" #define DEBUG_TYPE "definition-block-separator" namespace clang { diff --git a/clang/lib/Format/FormatToken.cpp b/clang/lib/Format/FormatToken.cpp index 665b2e43259b2..a63db8cc79527 100644 --- a/clang/lib/Format/FormatToken.cpp +++ b/clang/lib/Format/FormatToken.cpp @@ -14,9 +14,6 @@ #include "FormatToken.h" #include "ContinuationIndenter.h" -#include "llvm/ADT/SmallVector.h" -#include "llvm/Support/Debug.h" -#include namespace clang { namespace format { diff --git a/clang/lib/Format/FormatTokenLexer.cpp b/clang/lib/Format/FormatTokenLexer.cpp index 717eb6bb49b1f..a1c8df80e6a9f 100644 --- a/clang/lib/Format/FormatTokenLexer.cpp +++ b/clang/lib/Format/FormatTokenLexer.cpp @@ -13,11 +13,7 @@ //===----------------------------------------------------------------------===// #include "FormatTokenLexer.h" -#include "FormatToken.h" -#include "clang/Basic/SourceLocation.h" #include "clang/Basic/SourceManager.h" -#include "clang/Format/Format.h" -#include "llvm/Support/Regex.h" namespace clang { namespace format { diff --git a/clang/lib/Format/MacroCallReconstructor.cpp b/clang/lib/Format/MacroCallReconstructor.cpp index 101acefdfe7a3..5ba4f2c99a6af 100644 --- a/clang/lib/Format/MacroCallReconstructor.cpp +++ b/clang/lib/Format/MacroCallReconstructor.cpp @@ -16,10 +16,7 @@ #include "Macros.h" #include "UnwrappedLineParser.h" -#include "clang/Basic/TokenKinds.h" #include "llvm/ADT/DenseSet.h" -#include "llvm/Support/Debug.h" -#include #define DEBUG_TYPE "format-reconstruct" diff --git a/clang/lib/Format/MacroExpander.cpp b/clang/lib/Format/MacroExpander.cpp index 5a1cdd884c5e6..7668765764e8d 100644 --- a/clang/lib/Format/MacroExpander.cpp +++ b/clang/lib/Format/MacroExpander.cpp @@ -14,19 +14,8 @@ #include "Macros.h" -#include "Encoding.h" -#include "FormatToken.h" #include "FormatTokenLexer.h" -#include "clang/Basic/TokenKinds.h" -#include "clang/Format/Format.h" -#include "clang/Lex/HeaderSearch.h" -#include "clang/Lex/HeaderSearchOptions.h" -#include "clang/Lex/Lexer.h" -#include "clang/Lex/ModuleLoader.h" #include "clang/Lex/Preprocessor.h" -#include "clang/Lex/PreprocessorOptions.h" -#include "llvm/ADT/StringSet.h" -#include "llvm/Support/ErrorHandling.h" namespace clang { namespace format { diff --git a/clang/lib/Format/NamespaceEndCommentsFixer.cpp b/clang/lib/Format/NamespaceEndCommentsFixer.cpp index 08f8d6840fe00..010cc41f17683 100644 --- a/clang/lib/Format/NamespaceEndCommentsFixer.cpp +++ b/clang/lib/Format/NamespaceEndCommentsFixer.cpp @@ -13,9 +13,6 @@ //===----------------------------------------------------------------------===// #include "NamespaceEndCommentsFixer.h" -#include "clang/Basic/TokenKinds.h" -#include "llvm/Support/Debug.h" -#include "llvm/Support/Regex.h" #define DEBUG_TYPE "namespace-end-comments-fixer" diff --git a/clang/lib/Format/ObjCPropertyAttributeOrderFixer.cpp b/clang/lib/Format/ObjCPropertyAttributeOrderFixer.cpp index c91d6251425ea..6339d346fd9c7 100644 --- a/clang/lib/Format/ObjCPropertyAttributeOrderFixer.cpp +++ b/clang/lib/Format/ObjCPropertyAttributeOrderFixer.cpp @@ -15,8 +15,6 @@ #include "ObjCPropertyAttributeOrderFixer.h" -#include - namespace clang { namespace format { diff --git a/clang/lib/Format/QualifierAlignmentFixer.cpp b/clang/lib/Format/QualifierAlignmentFixer.cpp index a44c09056a0ed..32d5153fc8151 100644 --- a/clang/lib/Format/QualifierAlignmentFixer.cpp +++ b/clang/lib/Format/QualifierAlignmentFixer.cpp @@ -13,12 +13,6 @@ //===----------------------------------------------------------------------===// #include "QualifierAlignmentFixer.h" -#include "FormatToken.h" -#include "llvm/Support/Debug.h" -#include "llvm/Support/Regex.h" - -#include -#include #define DEBUG_TYPE "format-qualifier-alignment-fixer" diff --git a/clang/lib/Format/SortJavaScriptImports.cpp b/clang/lib/Format/SortJavaScriptImports.cpp index 1a6a1b19e7022..fda2ad8c311bf 100644 --- a/clang/lib/Format/SortJavaScriptImports.cpp +++ b/clang/lib/Format/SortJavaScriptImports.cpp @@ -13,19 +13,6 @@ #include "SortJavaScriptImports.h" #include "TokenAnalyzer.h" -#include "TokenAnnotator.h" -#include "clang/Basic/Diagnostic.h" -#include "clang/Basic/DiagnosticOptions.h" -#include "clang/Basic/LLVM.h" -#include "clang/Basic/SourceLocation.h" -#include "clang/Basic/SourceManager.h" -#include "clang/Basic/TokenKinds.h" -#include "clang/Format/Format.h" -#include "llvm/ADT/STLExtras.h" -#include "llvm/ADT/SmallVector.h" -#include "llvm/Support/Debug.h" -#include -#include #define DEBUG_TYPE "format-formatter" diff --git a/clang/lib/Format/TokenAnalyzer.cpp b/clang/lib/Format/TokenAnalyzer.cpp index bd648c430f9b0..2fdc2460bf67c 100644 --- a/clang/lib/Format/TokenAnalyzer.cpp +++ b/clang/lib/Format/TokenAnalyzer.cpp @@ -14,21 +14,6 @@ //===----------------------------------------------------------------------===// #include "TokenAnalyzer.h" -#include "AffectedRangeManager.h" -#include "Encoding.h" -#include "FormatToken.h" -#include "FormatTokenLexer.h" -#include "TokenAnnotator.h" -#include "UnwrappedLineParser.h" -#include "clang/Basic/Diagnostic.h" -#include "clang/Basic/DiagnosticOptions.h" -#include "clang/Basic/FileManager.h" -#include "clang/Basic/SourceManager.h" -#include "clang/Format/Format.h" -#include "llvm/ADT/STLExtras.h" -#include "llvm/ADT/SmallVector.h" -#include "llvm/Support/Debug.h" -#include #define DEBUG_TYPE "format-formatter" diff --git a/clang/lib/Format/TokenAnnotator.cpp b/clang/lib/Format/TokenAnnotator.cpp index 5a715ac8a5f23..f3458c20a71fa 100644 --- a/clang/lib/Format/TokenAnnotator.cpp +++ b/clang/lib/Format/TokenAnnotator.cpp @@ -13,11 +13,7 @@ //===----------------------------------------------------------------------===// #include "TokenAnnotator.h" -#include "FormatToken.h" -#include "clang/Basic/SourceManager.h" -#include "clang/Basic/TokenKinds.h" #include "llvm/ADT/SmallPtrSet.h" -#include "llvm/Support/Debug.h" #define DEBUG_TYPE "format-token-annotator" diff --git a/clang/lib/Format/UnwrappedLineFormatter.cpp b/clang/lib/Format/UnwrappedLineFormatter.cpp index fb31980ab9f49..bb5841f4e9263 100644 --- a/clang/lib/Format/UnwrappedLineFormatter.cpp +++ b/clang/lib/Format/UnwrappedLineFormatter.cpp @@ -7,10 +7,8 @@ //===----------------------------------------------------------------------===// #include "UnwrappedLineFormatter.h" -#include "FormatToken.h" #include "NamespaceEndCommentsFixer.h" #include "WhitespaceManager.h" -#include "llvm/Support/Debug.h" #include #define DEBUG_TYPE "format-formatter" diff --git a/clang/lib/Format/UnwrappedLineParser.cpp b/clang/lib/Format/UnwrappedLineParser.cpp index 2b893f7abe402..6ac4c7dc1a187 100644 --- a/clang/lib/Format/UnwrappedLineParser.cpp +++ b/clang/lib/Format/UnwrappedLineParser.cpp @@ -13,20 +13,9 @@ //===----------------------------------------------------------------------===// #include "UnwrappedLineParser.h" -#include "FormatToken.h" -#include "FormatTokenLexer.h" #include "FormatTokenSource.h" -#include "Macros.h" #include "TokenAnnotator.h" -#include "clang/Basic/TokenKinds.h" -#include "llvm/ADT/STLExtras.h" -#include "llvm/ADT/StringRef.h" -#include "llvm/Support/Debug.h" #include "llvm/Support/raw_os_ostream.h" -#include "llvm/Support/raw_ostream.h" - -#include -#include #define DEBUG_TYPE "format-parser" diff --git a/clang/lib/Format/UsingDeclarationsSorter.cpp b/clang/lib/Format/UsingDeclarationsSorter.cpp index 2f4b1e0e46270..3543f86b1a65a 100644 --- a/clang/lib/Format/UsingDeclarationsSorter.cpp +++ b/clang/lib/Format/UsingDeclarationsSorter.cpp @@ -13,11 +13,6 @@ //===----------------------------------------------------------------------===// #include "UsingDeclarationsSorter.h" -#include "clang/Format/Format.h" -#include "llvm/Support/Debug.h" -#include "llvm/Support/Regex.h" - -#include #define DEBUG_TYPE "using-declarations-sorter" diff --git a/clang/lib/Format/WhitespaceManager.cpp b/clang/lib/Format/WhitespaceManager.cpp index 753be25bfd675..6577c19cdf797 100644 --- a/clang/lib/Format/WhitespaceManager.cpp +++ b/clang/lib/Format/WhitespaceManager.cpp @@ -12,9 +12,6 @@ //===----------------------------------------------------------------------===// #include "WhitespaceManager.h" -#include "llvm/ADT/STLExtras.h" -#include "llvm/ADT/SmallVector.h" -#include namespace clang { namespace format { diff --git a/clang/tools/clang-format/ClangFormat.cpp b/clang/tools/clang-format/ClangFormat.cpp index e122cea50f726..60b0f5d1a0f41 100644 --- a/clang/tools/clang-format/ClangFormat.cpp +++ b/clang/tools/clang-format/ClangFormat.cpp @@ -13,18 +13,12 @@ //===----------------------------------------------------------------------===// #include "../../lib/Format/MatchFilePath.h" -#include "clang/Basic/Diagnostic.h" -#include "clang/Basic/DiagnosticOptions.h" -#include "clang/Basic/FileManager.h" #include "clang/Basic/SourceManager.h" #include "clang/Basic/Version.h" #include "clang/Format/Format.h" #include "clang/Rewrite/Core/Rewriter.h" -#include "llvm/ADT/StringSwitch.h" #include "llvm/Support/CommandLine.h" -#include "llvm/Support/FileSystem.h" #include "llvm/Support/InitLLVM.h" -#include "llvm/Support/Process.h" #include using namespace llvm;