From 6ddb524b9145700a4e9b4b2da030a6896b3e9d7b Mon Sep 17 00:00:00 2001 From: kai Date: Fri, 11 Jan 2013 22:46:36 +0100 Subject: [PATCH] More LLVM 3.3 changes --- driver/main.cpp | 3 ++- gen/functions.cpp | 4 ++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/driver/main.cpp b/driver/main.cpp index 73b2b0ca..84a91b2d 100644 --- a/driver/main.cpp +++ b/driver/main.cpp @@ -9,11 +9,12 @@ #include "gen/llvmcompat.h" #include "gen/llvm.h" -#include "llvm/LinkAllVMCore.h" #include "llvm/Linker.h" #if LDC_LLVM_VER >= 303 +#include "llvm/LinkAllIR.h" #include "llvm/IR/LLVMContext.h" #else +#include "llvm/LinkAllVMCore.h" #include "llvm/LLVMContext.h" #endif #include "llvm/Target/TargetMachine.h" diff --git a/gen/functions.cpp b/gen/functions.cpp index 4d5ed2e0..989bf6e2 100644 --- a/gen/functions.cpp +++ b/gen/functions.cpp @@ -349,7 +349,11 @@ LLFunction* DtoInlineIRFunction(FuncDeclaration* fdecl) if(errstr != "") error(tinst->loc, "can't parse inline LLVM IR:\n%s\n%s\n%s\nThe input string was: \n%s", +#if LDC_LLVM_VER >= 303 + err.getLineContents().str().c_str(), +#else err.getLineContents().c_str(), +#endif (std::string(err.getColumnNo(), ' ') + '^').c_str(), errstr.c_str(), stream.str().c_str());