|* *|
\*===----------------------------------------------------------------------===*/
-#include "llvm-c/Core.h"
#include "llvm-c/Analysis.h"
+#include "llvm-c/Core.h"
#include "caml/alloc.h"
#include "caml/mlvalues.h"
#include "caml/memory.h"
\*===----------------------------------------------------------------------===*/
#include "llvm-c/BitReader.h"
+#include "llvm-c/Core.h"
#include "caml/alloc.h"
#include "caml/fail.h"
#include "caml/memory.h"
LLVMModuleRef M;
if (LLVMGetBitcodeModuleInContext2(C, MemBuf, &M))
- llvm_raise(*caml_named_value("Llvm_bitreader.Error"), "");
+ llvm_raise(*caml_named_value("Llvm_bitreader.Error"), LLVMCreateMessage(""));
return M;
}
LLVMModuleRef M;
if (LLVMParseBitcodeInContext2(C, MemBuf, &M))
- llvm_raise(*caml_named_value("Llvm_bitreader.Error"), "");
+ llvm_raise(*caml_named_value("Llvm_bitreader.Error"), LLVMCreateMessage(""));
return M;
}
|* *|
\*===----------------------------------------------------------------------===*/
+#include "llvm-c/Core.h"
#include "llvm-c/Linker.h"
#include "caml/alloc.h"
#include "caml/memory.h"
/* llmodule -> llmodule -> unit */
CAMLprim value llvm_link_modules(LLVMModuleRef Dst, LLVMModuleRef Src) {
if (LLVMLinkModules2(Dst, Src))
- llvm_raise(*caml_named_value("Llvm_linker.Error"), "Linking failed");
+ llvm_raise(*caml_named_value("Llvm_linker.Error"), LLVMCreateMessage("Linking failed"));
return Val_unit;
}
#include <stdlib.h>
#include <string.h>
#include "llvm-c/Core.h"
+#include "llvm-c/Support.h"
#include "caml/alloc.h"
#include "caml/custom.h"
#include "caml/memory.h"