Skip to content

Commit 426e694

Browse files
committedMar 16, 2024·
[clang-format][NFC] Delete redundant and extraneous #include lines
1 parent 53c4418 commit 426e694

15 files changed

+0
-87
lines changed
 

‎clang/lib/Format/BreakableToken.h

-3
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,8 @@
1818
#define LLVM_CLANG_LIB_FORMAT_BREAKABLETOKEN_H
1919

2020
#include "Encoding.h"
21-
#include "TokenAnnotator.h"
2221
#include "WhitespaceManager.h"
2322
#include "llvm/ADT/StringSet.h"
24-
#include "llvm/Support/Regex.h"
25-
#include <utility>
2623

2724
namespace clang {
2825
namespace format {

‎clang/lib/Format/ContinuationIndenter.h

-5
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,6 @@
1717

1818
#include "Encoding.h"
1919
#include "FormatToken.h"
20-
#include "clang/Format/Format.h"
21-
#include "llvm/Support/Regex.h"
22-
#include <map>
23-
#include <optional>
24-
#include <tuple>
2520

2621
namespace clang {
2722
class SourceManager;

‎clang/lib/Format/Encoding.h

-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
#define LLVM_CLANG_LIB_FORMAT_ENCODING_H
1717

1818
#include "clang/Basic/LLVM.h"
19-
#include "llvm/ADT/StringRef.h"
2019
#include "llvm/Support/ConvertUTF.h"
2120
#include "llvm/Support/Unicode.h"
2221

‎clang/lib/Format/Format.cpp

-28
Original file line numberDiff line numberDiff line change
@@ -13,44 +13,16 @@
1313
//===----------------------------------------------------------------------===//
1414

1515
#include "clang/Format/Format.h"
16-
#include "AffectedRangeManager.h"
17-
#include "BreakableToken.h"
18-
#include "ContinuationIndenter.h"
1916
#include "DefinitionBlockSeparator.h"
20-
#include "FormatInternal.h"
21-
#include "FormatToken.h"
22-
#include "FormatTokenLexer.h"
2317
#include "IntegerLiteralSeparatorFixer.h"
2418
#include "NamespaceEndCommentsFixer.h"
2519
#include "ObjCPropertyAttributeOrderFixer.h"
2620
#include "QualifierAlignmentFixer.h"
2721
#include "SortJavaScriptImports.h"
28-
#include "TokenAnalyzer.h"
29-
#include "TokenAnnotator.h"
3022
#include "UnwrappedLineFormatter.h"
31-
#include "UnwrappedLineParser.h"
3223
#include "UsingDeclarationsSorter.h"
33-
#include "WhitespaceManager.h"
34-
#include "clang/Basic/Diagnostic.h"
35-
#include "clang/Basic/DiagnosticOptions.h"
36-
#include "clang/Basic/SourceManager.h"
37-
#include "clang/Lex/Lexer.h"
3824
#include "clang/Tooling/Inclusions/HeaderIncludes.h"
39-
#include "llvm/ADT/STLExtras.h"
4025
#include "llvm/ADT/Sequence.h"
41-
#include "llvm/ADT/StringRef.h"
42-
#include "llvm/Support/Allocator.h"
43-
#include "llvm/Support/Debug.h"
44-
#include "llvm/Support/Path.h"
45-
#include "llvm/Support/Regex.h"
46-
#include "llvm/Support/VirtualFileSystem.h"
47-
#include "llvm/Support/YAMLTraits.h"
48-
#include <algorithm>
49-
#include <memory>
50-
#include <mutex>
51-
#include <optional>
52-
#include <string>
53-
#include <unordered_map>
5426

5527
#define DEBUG_TYPE "format-formatter"
5628

‎clang/lib/Format/FormatInternal.h

-3
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,6 @@
1515
#ifndef LLVM_CLANG_LIB_FORMAT_FORMATINTERNAL_H
1616
#define LLVM_CLANG_LIB_FORMAT_FORMATINTERNAL_H
1717

18-
#include "BreakableToken.h"
19-
#include <utility>
20-
2118
namespace clang {
2219
namespace format {
2320
namespace internal {

‎clang/lib/Format/FormatToken.h

-2
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,6 @@
1919
#include "clang/Basic/OperatorPrecedence.h"
2020
#include "clang/Format/Format.h"
2121
#include "clang/Lex/Lexer.h"
22-
#include <memory>
23-
#include <optional>
2422
#include <unordered_set>
2523

2624
namespace clang {

‎clang/lib/Format/FormatTokenLexer.h

-5
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,9 @@
1717

1818
#include "Encoding.h"
1919
#include "FormatToken.h"
20-
#include "clang/Basic/LangOptions.h"
21-
#include "clang/Basic/SourceLocation.h"
22-
#include "clang/Basic/SourceManager.h"
23-
#include "clang/Format/Format.h"
2420
#include "llvm/ADT/MapVector.h"
2521
#include "llvm/ADT/SmallPtrSet.h"
2622
#include "llvm/ADT/StringSet.h"
27-
#include "llvm/Support/Regex.h"
2823

2924
#include <stack>
3025

‎clang/lib/Format/FormatTokenSource.h

-3
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,7 @@
1515
#ifndef LLVM_CLANG_LIB_FORMAT_FORMATTOKENSOURCE_H
1616
#define LLVM_CLANG_LIB_FORMAT_FORMATTOKENSOURCE_H
1717

18-
#include "FormatToken.h"
1918
#include "UnwrappedLineParser.h"
20-
#include "llvm/ADT/DenseMap.h"
21-
#include <cstddef>
2219

2320
#define DEBUG_TYPE "format-token-source"
2421

‎clang/lib/Format/Macros.h

-6
Original file line numberDiff line numberDiff line change
@@ -39,15 +39,9 @@
3939
#define CLANG_LIB_FORMAT_MACROS_H
4040

4141
#include <list>
42-
#include <map>
43-
#include <string>
44-
#include <vector>
4542

4643
#include "FormatToken.h"
47-
#include "llvm/ADT/ArrayRef.h"
4844
#include "llvm/ADT/DenseMap.h"
49-
#include "llvm/ADT/SmallVector.h"
50-
#include "llvm/ADT/StringRef.h"
5145

5246
namespace clang {
5347
namespace format {

‎clang/lib/Format/SortJavaScriptImports.h

-3
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,7 @@
1414
#ifndef LLVM_CLANG_LIB_FORMAT_SORTJAVASCRIPTIMPORTS_H
1515
#define LLVM_CLANG_LIB_FORMAT_SORTJAVASCRIPTIMPORTS_H
1616

17-
#include "clang/Basic/LLVM.h"
1817
#include "clang/Format/Format.h"
19-
#include "llvm/ADT/ArrayRef.h"
20-
#include "llvm/ADT/StringRef.h"
2118

2219
namespace clang {
2320
namespace format {

‎clang/lib/Format/TokenAnalyzer.h

-11
Original file line numberDiff line numberDiff line change
@@ -17,19 +17,8 @@
1717
#define LLVM_CLANG_LIB_FORMAT_TOKENANALYZER_H
1818

1919
#include "AffectedRangeManager.h"
20-
#include "Encoding.h"
21-
#include "FormatToken.h"
2220
#include "FormatTokenLexer.h"
2321
#include "TokenAnnotator.h"
24-
#include "UnwrappedLineParser.h"
25-
#include "clang/Basic/Diagnostic.h"
26-
#include "clang/Basic/DiagnosticOptions.h"
27-
#include "clang/Basic/FileManager.h"
28-
#include "clang/Basic/SourceManager.h"
29-
#include "clang/Format/Format.h"
30-
#include "llvm/ADT/STLExtras.h"
31-
#include "llvm/Support/Debug.h"
32-
#include <memory>
3322

3423
namespace clang {
3524
namespace format {

‎clang/lib/Format/TokenAnnotator.h

-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
#define LLVM_CLANG_LIB_FORMAT_TOKENANNOTATOR_H
1717

1818
#include "UnwrappedLineParser.h"
19-
#include "clang/Format/Format.h"
2019

2120
namespace clang {
2221
namespace format {

‎clang/lib/Format/UnwrappedLineFormatter.h

-2
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,6 @@
1616
#define LLVM_CLANG_LIB_FORMAT_UNWRAPPEDLINEFORMATTER_H
1717

1818
#include "ContinuationIndenter.h"
19-
#include "clang/Format/Format.h"
20-
#include <map>
2119

2220
namespace clang {
2321
namespace format {

‎clang/lib/Format/UnwrappedLineParser.h

-9
Original file line numberDiff line numberDiff line change
@@ -15,17 +15,8 @@
1515
#ifndef LLVM_CLANG_LIB_FORMAT_UNWRAPPEDLINEPARSER_H
1616
#define LLVM_CLANG_LIB_FORMAT_UNWRAPPEDLINEPARSER_H
1717

18-
#include "Encoding.h"
19-
#include "FormatToken.h"
2018
#include "Macros.h"
21-
#include "clang/Basic/IdentifierTable.h"
22-
#include "clang/Format/Format.h"
23-
#include "llvm/ADT/ArrayRef.h"
24-
#include "llvm/ADT/BitVector.h"
25-
#include "llvm/Support/Regex.h"
26-
#include <list>
2719
#include <stack>
28-
#include <vector>
2920

3021
namespace clang {
3122
namespace format {

‎clang/lib/Format/WhitespaceManager.h

-5
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,6 @@
1717

1818
#include "TokenAnnotator.h"
1919
#include "clang/Basic/SourceManager.h"
20-
#include "clang/Format/Format.h"
21-
#include "llvm/ADT/SmallVector.h"
22-
#include <algorithm>
23-
#include <string>
24-
#include <tuple>
2520

2621
namespace clang {
2722
namespace format {

0 commit comments

Comments
 (0)
Please sign in to comment.