[llvm] r318489 - Don't #include MemoryBuffer.h from Host.h.
Zachary Turner via llvm-commits
llvm-commits at lists.llvm.org
Thu Nov 16 17:00:35 PST 2017
Author: zturner
Date: Thu Nov 16 17:00:35 2017
New Revision: 318489
URL: http://llvm.org/viewvc/llvm-project?rev=318489&view=rev
Log:
Don't #include MemoryBuffer.h from Host.h.
It turns out this #include isn't used from Host.h anyway,
but by having it it causes circular include dependencies.
This issues only surfaced while I was working on a separate
patch, so I'm submitting this first so that it's independent
of the other, unrelated patch.
Modified:
llvm/trunk/include/llvm/ADT/StringExtras.h
llvm/trunk/include/llvm/DebugInfo/PDB/Native/NativeSession.h
llvm/trunk/include/llvm/MC/MCFragment.h
llvm/trunk/include/llvm/Support/CodeGenCoverage.h
llvm/trunk/include/llvm/Support/Host.h
llvm/trunk/lib/DebugInfo/PDB/PDB.cpp
llvm/trunk/lib/Support/CodeGenCoverage.cpp
llvm/trunk/tools/llvm-mt/llvm-mt.cpp
llvm/trunk/tools/llvm-rc/ResourceFileWriter.cpp
llvm/trunk/tools/llvm-rc/ResourceFileWriter.h
llvm/trunk/tools/llvm-rc/llvm-rc.cpp
Modified: llvm/trunk/include/llvm/ADT/StringExtras.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/ADT/StringExtras.h?rev=318489&r1=318488&r2=318489&view=diff
==============================================================================
--- llvm/trunk/include/llvm/ADT/StringExtras.h (original)
+++ llvm/trunk/include/llvm/ADT/StringExtras.h Thu Nov 16 17:00:35 2017
@@ -17,6 +17,7 @@
#include "llvm/ADT/ArrayRef.h"
#include "llvm/ADT/SmallString.h"
#include "llvm/ADT/StringRef.h"
+#include "llvm/ADT/Twine.h"
#include <cassert>
#include <cstddef>
#include <cstdint>
Modified: llvm/trunk/include/llvm/DebugInfo/PDB/Native/NativeSession.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/DebugInfo/PDB/Native/NativeSession.h?rev=318489&r1=318488&r2=318489&view=diff
==============================================================================
--- llvm/trunk/include/llvm/DebugInfo/PDB/Native/NativeSession.h (original)
+++ llvm/trunk/include/llvm/DebugInfo/PDB/Native/NativeSession.h Thu Nov 16 17:00:35 2017
@@ -22,6 +22,7 @@
#include "llvm/Support/Error.h"
namespace llvm {
+class MemoryBuffer;
namespace pdb {
class PDBFile;
Modified: llvm/trunk/include/llvm/MC/MCFragment.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/MC/MCFragment.h?rev=318489&r1=318488&r2=318489&view=diff
==============================================================================
--- llvm/trunk/include/llvm/MC/MCFragment.h (original)
+++ llvm/trunk/include/llvm/MC/MCFragment.h Thu Nov 16 17:00:35 2017
@@ -17,6 +17,7 @@
#include "llvm/ADT/ilist_node.h"
#include "llvm/MC/MCFixup.h"
#include "llvm/MC/MCInst.h"
+#include "llvm/Support/Casting.h"
#include "llvm/Support/SMLoc.h"
#include <cstdint>
#include <utility>
Modified: llvm/trunk/include/llvm/Support/CodeGenCoverage.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/CodeGenCoverage.h?rev=318489&r1=318488&r2=318489&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Support/CodeGenCoverage.h (original)
+++ llvm/trunk/include/llvm/Support/CodeGenCoverage.h Thu Nov 16 17:00:35 2017
@@ -17,6 +17,7 @@
namespace llvm {
class LLVMContext;
+class MemoryBuffer;
class CodeGenCoverage {
protected:
Modified: llvm/trunk/include/llvm/Support/Host.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/Host.h?rev=318489&r1=318488&r2=318489&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Support/Host.h (original)
+++ llvm/trunk/include/llvm/Support/Host.h Thu Nov 16 17:00:35 2017
@@ -15,7 +15,6 @@
#define LLVM_SUPPORT_HOST_H
#include "llvm/ADT/StringMap.h"
-#include "llvm/Support/MemoryBuffer.h"
#if defined(__linux__) || defined(__GNU__) || defined(__HAIKU__)
#include <endian.h>
Modified: llvm/trunk/lib/DebugInfo/PDB/PDB.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/DebugInfo/PDB/PDB.cpp?rev=318489&r1=318488&r2=318489&view=diff
==============================================================================
--- llvm/trunk/lib/DebugInfo/PDB/PDB.cpp (original)
+++ llvm/trunk/lib/DebugInfo/PDB/PDB.cpp Thu Nov 16 17:00:35 2017
@@ -16,6 +16,7 @@
#endif
#include "llvm/DebugInfo/PDB/Native/NativeSession.h"
#include "llvm/Support/Error.h"
+#include "llvm/Support/MemoryBuffer.h"
using namespace llvm;
using namespace llvm::pdb;
Modified: llvm/trunk/lib/Support/CodeGenCoverage.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/CodeGenCoverage.cpp?rev=318489&r1=318488&r2=318489&view=diff
==============================================================================
--- llvm/trunk/lib/Support/CodeGenCoverage.cpp (original)
+++ llvm/trunk/lib/Support/CodeGenCoverage.cpp Thu Nov 16 17:00:35 2017
@@ -14,6 +14,7 @@
#include "llvm/Support/Endian.h"
#include "llvm/Support/FileSystem.h"
+#include "llvm/Support/MemoryBuffer.h"
#include "llvm/Support/Mutex.h"
#include "llvm/Support/ScopedPrinter.h"
#include "llvm/Support/ToolOutputFile.h"
Modified: llvm/trunk/tools/llvm-mt/llvm-mt.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-mt/llvm-mt.cpp?rev=318489&r1=318488&r2=318489&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-mt/llvm-mt.cpp (original)
+++ llvm/trunk/tools/llvm-mt/llvm-mt.cpp Thu Nov 16 17:00:35 2017
@@ -18,6 +18,7 @@
#include "llvm/Support/Error.h"
#include "llvm/Support/FileOutputBuffer.h"
#include "llvm/Support/ManagedStatic.h"
+#include "llvm/Support/MemoryBuffer.h"
#include "llvm/Support/Path.h"
#include "llvm/Support/PrettyStackTrace.h"
#include "llvm/Support/Process.h"
Modified: llvm/trunk/tools/llvm-rc/ResourceFileWriter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-rc/ResourceFileWriter.cpp?rev=318489&r1=318488&r2=318489&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-rc/ResourceFileWriter.cpp (original)
+++ llvm/trunk/tools/llvm-rc/ResourceFileWriter.cpp Thu Nov 16 17:00:35 2017
@@ -17,6 +17,7 @@
#include "llvm/Support/ConvertUTF.h"
#include "llvm/Support/Endian.h"
#include "llvm/Support/EndianStream.h"
+#include "llvm/Support/MemoryBuffer.h"
#include "llvm/Support/Path.h"
#include "llvm/Support/Process.h"
Modified: llvm/trunk/tools/llvm-rc/ResourceFileWriter.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-rc/ResourceFileWriter.h?rev=318489&r1=318488&r2=318489&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-rc/ResourceFileWriter.h (original)
+++ llvm/trunk/tools/llvm-rc/ResourceFileWriter.h Thu Nov 16 17:00:35 2017
@@ -20,6 +20,9 @@
#include "llvm/Support/Endian.h"
namespace llvm {
+
+class MemoryBuffer;
+
namespace rc {
struct SearchParams {
Modified: llvm/trunk/tools/llvm-rc/llvm-rc.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-rc/llvm-rc.cpp?rev=318489&r1=318488&r2=318489&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-rc/llvm-rc.cpp (original)
+++ llvm/trunk/tools/llvm-rc/llvm-rc.cpp Thu Nov 16 17:00:35 2017
@@ -22,6 +22,7 @@
#include "llvm/Support/Error.h"
#include "llvm/Support/FileSystem.h"
#include "llvm/Support/ManagedStatic.h"
+#include "llvm/Support/MemoryBuffer.h"
#include "llvm/Support/PrettyStackTrace.h"
#include "llvm/Support/Process.h"
#include "llvm/Support/Signals.h"
More information about the llvm-commits
mailing list