aboutsummaryrefslogtreecommitdiff
path: root/clang/lib
diff options
context:
space:
mode:
authorBill Wendling <5993918+bwendling@users.noreply.github.com>2023-09-14 02:29:11 -0700
committerGitHub <noreply@github.com>2023-09-14 02:29:11 -0700
commit0009032a27f7c8461b7c107cb05b1eac61be7197 (patch)
treef072b921f13a642bf85b8c979bf0112203b80a89 /clang/lib
parent7e6a5fe1603f3f768e299de0bea2cde8bc3c31db (diff)
downloadllvm-0009032a27f7c8461b7c107cb05b1eac61be7197.zip
llvm-0009032a27f7c8461b7c107cb05b1eac61be7197.tar.gz
llvm-0009032a27f7c8461b7c107cb05b1eac61be7197.tar.bz2
[NFC] Minimize header includes (#66339)
Minimize the headers included in header files to reduce the number of files that need recompiled after a change.
Diffstat (limited to 'clang/lib')
-rw-r--r--clang/lib/Basic/Attributes.cpp16
-rw-r--r--clang/lib/Basic/IdentifierTable.cpp4
-rw-r--r--clang/lib/Parse/ParseStmt.cpp1
3 files changed, 17 insertions, 4 deletions
diff --git a/clang/lib/Basic/Attributes.cpp b/clang/lib/Basic/Attributes.cpp
index 1308e2d..bb49521 100644
--- a/clang/lib/Basic/Attributes.cpp
+++ b/clang/lib/Basic/Attributes.cpp
@@ -1,8 +1,22 @@
+//===--- Attributes.cpp ---------------------------------------------------===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+//
+//===----------------------------------------------------------------------===//
+//
+// This file implements the AttributeCommonInfo interface.
+//
+//===----------------------------------------------------------------------===//
+
#include "clang/Basic/Attributes.h"
#include "clang/Basic/AttrSubjectMatchRules.h"
-#include "clang/Basic/AttributeCommonInfo.h"
#include "clang/Basic/IdentifierTable.h"
+#include "clang/Basic/LangOptions.h"
#include "clang/Basic/ParsedAttrInfo.h"
+#include "clang/Basic/TargetInfo.h"
+
using namespace clang;
static int hasAttributeImpl(AttributeCommonInfo::Syntax Syntax, StringRef Name,
diff --git a/clang/lib/Basic/IdentifierTable.cpp b/clang/lib/Basic/IdentifierTable.cpp
index afb3026..e5599d5 100644
--- a/clang/lib/Basic/IdentifierTable.cpp
+++ b/clang/lib/Basic/IdentifierTable.cpp
@@ -25,7 +25,6 @@
#include "llvm/ADT/StringMap.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/Support/Allocator.h"
-#include "llvm/Support/ErrorHandling.h"
#include "llvm/Support/raw_ostream.h"
#include <cassert>
#include <cstdio>
@@ -52,8 +51,7 @@ namespace {
/// A simple identifier lookup iterator that represents an
/// empty sequence of identifiers.
-class EmptyLookupIterator : public IdentifierIterator
-{
+class EmptyLookupIterator : public IdentifierIterator {
public:
StringRef Next() override { return StringRef(); }
};
diff --git a/clang/lib/Parse/ParseStmt.cpp b/clang/lib/Parse/ParseStmt.cpp
index fb883c0..2531147 100644
--- a/clang/lib/Parse/ParseStmt.cpp
+++ b/clang/lib/Parse/ParseStmt.cpp
@@ -14,6 +14,7 @@
#include "clang/AST/PrettyDeclStackTrace.h"
#include "clang/Basic/Attributes.h"
#include "clang/Basic/PrettyStackTrace.h"
+#include "clang/Basic/TargetInfo.h"
#include "clang/Basic/TokenKinds.h"
#include "clang/Parse/LoopHint.h"
#include "clang/Parse/Parser.h"