support LLVM build

This commit is contained in:
Ilia Filippov
2014-06-18 17:53:42 +04:00
parent 5e14469ea6
commit 76ea59b40b
2 changed files with 5 additions and 3 deletions

View File

@@ -707,7 +707,7 @@ AddBitcodeToModule(const unsigned char *bitcode, int length,
llvm::MemoryBuffer *bcBuf = llvm::MemoryBuffer::getMemBuffer(sb);
#if defined(LLVM_3_5)
llvm::ErrorOr<llvm::Module *> ModuleOrErr = llvm::parseBitcodeFile(bcBuf, *g->ctx);
if (llvm::error_code EC = ModuleOrErr.getError())
if (std::error_code EC = ModuleOrErr.getError())
Error(SourcePos(), "Error parsing stdlib bitcode: %s", EC.message().c_str());
else {
llvm::Module *bcModule = ModuleOrErr.get();