diff options
Diffstat (limited to 'contrib/llvm/lib/ExecutionEngine/Interpreter/Interpreter.cpp')
-rw-r--r-- | contrib/llvm/lib/ExecutionEngine/Interpreter/Interpreter.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/contrib/llvm/lib/ExecutionEngine/Interpreter/Interpreter.cpp b/contrib/llvm/lib/ExecutionEngine/Interpreter/Interpreter.cpp index 9ee9d94..814efcc 100644 --- a/contrib/llvm/lib/ExecutionEngine/Interpreter/Interpreter.cpp +++ b/contrib/llvm/lib/ExecutionEngine/Interpreter/Interpreter.cpp @@ -34,9 +34,12 @@ extern "C" void LLVMLinkInInterpreter() { } /// ExecutionEngine *Interpreter::create(Module *M, std::string* ErrStr) { // Tell this Module to materialize everything and release the GVMaterializer. - if (M->MaterializeAllPermanently(ErrStr)) + if (std::error_code EC = M->materializeAllPermanently()) { + if (ErrStr) + *ErrStr = EC.message(); // We got an error, just return 0 - return 0; + return nullptr; + } return new Interpreter(M); } |