[clang] 7d6283f - [NFC] Remove unneeded header includes
Bill Wendling via cfe-commits
cfe-commits at lists.llvm.org
Tue Sep 5 13:12:10 PDT 2023
Author: Bill Wendling
Date: 2023-09-05T13:12:00-07:00
New Revision: 7d6283fd09016fda711a3ad211be7d25336dabc6
URL: https://github.com/llvm/llvm-project/commit/7d6283fd09016fda711a3ad211be7d25336dabc6
DIFF: https://github.com/llvm/llvm-project/commit/7d6283fd09016fda711a3ad211be7d25336dabc6.diff
LOG: [NFC] Remove unneeded header includes
Use forward decls instead of #including the header files.
Differential Revision: https://reviews.llvm.org/D159421
Added:
Modified:
clang/include/clang/AST/ASTContext.h
clang/lib/AST/ASTContext.cpp
clang/lib/CodeGen/CodeGenModule.h
Removed:
################################################################################
diff --git a/clang/include/clang/AST/ASTContext.h b/clang/include/clang/AST/ASTContext.h
index 8dc8bc262bbe3c..ec6b579870abbd 100644
--- a/clang/include/clang/AST/ASTContext.h
+++ b/clang/include/clang/AST/ASTContext.h
@@ -24,14 +24,9 @@
#include "clang/AST/PrettyPrinter.h"
#include "clang/AST/RawCommentList.h"
#include "clang/AST/TemplateName.h"
-#include "clang/Basic/IdentifierTable.h"
#include "clang/Basic/LLVM.h"
-#include "clang/Basic/LangOptions.h"
-#include "clang/Basic/NoSanitizeList.h"
#include "clang/Basic/PartialDiagnostic.h"
-#include "clang/Basic/ProfileList.h"
#include "clang/Basic/SourceLocation.h"
-#include "clang/Basic/XRayLists.h"
#include "llvm/ADT/DenseMap.h"
#include "llvm/ADT/DenseSet.h"
#include "llvm/ADT/FoldingSet.h"
@@ -62,6 +57,7 @@ class ASTMutationListener;
class ASTRecordLayout;
class AtomicExpr;
class BlockExpr;
+struct BlockVarCopyInit;
class BuiltinTemplateDecl;
class CharUnits;
class ConceptDecl;
@@ -70,17 +66,19 @@ class CXXConstructorDecl;
class CXXMethodDecl;
class CXXRecordDecl;
class DiagnosticsEngine;
-class ParentMapContext;
class DynTypedNodeList;
class Expr;
enum class FloatModeKind;
class GlobalDecl;
+class IdentifierTable;
+class LangOptions;
class MangleContext;
class MangleNumberingContext;
class MemberSpecializationInfo;
class Module;
struct MSGuidDeclParts;
class NestedNameSpecifier;
+class NoSanitizeList;
class ObjCCategoryDecl;
class ObjCCategoryImplDecl;
class ObjCContainerDecl;
@@ -94,8 +92,10 @@ class ObjCPropertyImplDecl;
class ObjCProtocolDecl;
class ObjCTypeParamDecl;
class OMPTraitInfo;
+class ParentMapContext;
struct ParsedTargetAttr;
class Preprocessor;
+class ProfileList;
class StoredDeclsMap;
class TargetAttr;
class TargetInfo;
@@ -108,7 +108,7 @@ class UnresolvedSetIterator;
class UsingShadowDecl;
class VarTemplateDecl;
class VTableContextBase;
-struct BlockVarCopyInit;
+class XRayFunctionFilter;
namespace Builtin {
diff --git a/clang/lib/AST/ASTContext.cpp b/clang/lib/AST/ASTContext.cpp
index 56617d37b8bcaf..4b1d9e86797b77 100644
--- a/clang/lib/AST/ASTContext.cpp
+++ b/clang/lib/AST/ASTContext.cpp
@@ -58,6 +58,7 @@
#include "clang/Basic/Module.h"
#include "clang/Basic/NoSanitizeList.h"
#include "clang/Basic/ObjCRuntime.h"
+#include "clang/Basic/ProfileList.h"
#include "clang/Basic/SourceLocation.h"
#include "clang/Basic/SourceManager.h"
#include "clang/Basic/Specifiers.h"
diff --git a/clang/lib/CodeGen/CodeGenModule.h b/clang/lib/CodeGen/CodeGenModule.h
index 2dcaaac4989624..79f48b6e2cda13 100644
--- a/clang/lib/CodeGen/CodeGenModule.h
+++ b/clang/lib/CodeGen/CodeGenModule.h
@@ -26,6 +26,7 @@
#include "clang/Basic/LangOptions.h"
#include "clang/Basic/Module.h"
#include "clang/Basic/NoSanitizeList.h"
+#include "clang/Basic/ProfileList.h"
#include "clang/Basic/TargetInfo.h"
#include "clang/Basic/XRayLists.h"
#include "clang/Lex/PreprocessorOptions.h"
More information about the cfe-commits
mailing list