OSDN Git Service

Fix another ordering constraint with windows.h and comment about
authorChandler Carruth <chandlerc@gmail.com>
Tue, 6 Jun 2017 12:43:20 +0000 (12:43 +0000)
committerChandler Carruth <chandlerc@gmail.com>
Tue, 6 Jun 2017 12:43:20 +0000 (12:43 +0000)
a revers constraint that we got right (by chance).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@304792 91177308-0d34-0410-b5e6-96231b3b80d8

lib/DebugInfo/Symbolize/Symbolize.cpp
lib/Support/Atomic.cpp

index 57c818f..0561d6a 100644 (file)
 #include <cstring>
 
 #if defined(_MSC_VER)
-#include <DbgHelp.h>
 #include <Windows.h>
+
+// This must be included after windows.h.
+#include <DbgHelp.h>
 #pragma comment(lib, "dbghelp.lib")
 
 // Windows.h conflicts with our COFF header definitions.
index 80550e2..55910c4 100644 (file)
@@ -18,6 +18,8 @@ using namespace llvm;
 
 #if defined(_MSC_VER)
 #include <Intrin.h>
+
+// We must include windows.h after Intrin.h.
 #include <windows.h>
 #undef MemoryFence
 #endif