From 56db241e8be7d750d61321d7a528aae627b3c82f Mon Sep 17 00:00:00 2001 From: Artyom Skrobov Date: Tue, 13 May 2014 11:16:22 +0000 Subject: [PATCH] Fix build failure with MSVC, following r208680 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208684 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/IR/DataLayout.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/include/llvm/IR/DataLayout.h b/include/llvm/IR/DataLayout.h index cd096dcbb50..3079dec7835 100644 --- a/include/llvm/IR/DataLayout.h +++ b/include/llvm/IR/DataLayout.h @@ -27,6 +27,9 @@ #include "llvm/Pass.h" #include "llvm/Support/DataTypes.h" +// this needs to be outside of the namespace, to avoid conflict with llvm-c decl +typedef struct LLVMOpaqueTargetData *LLVMTargetDataRef; + namespace llvm { class Value; @@ -445,8 +448,6 @@ public: } }; -typedef struct LLVMOpaqueTargetData *LLVMTargetDataRef; - inline DataLayout *unwrap(LLVMTargetDataRef P) { return reinterpret_cast(P); } -- 2.34.1