[llvm-commits] [llvm] r97368 - /llvm/trunk/bindings/ocaml/llvm/llvm_ocaml.c
Erick Tryzelaar
idadesub at users.sourceforge.net
Sat Feb 27 21:51:16 PST 2010
Author: erickt
Date: Sat Feb 27 23:51:16 2010
New Revision: 97368
URL: http://llvm.org/viewvc/llvm-project?rev=97368&view=rev
Log:
Fix incorrect uses of an ocaml llbuilder without extracting it from ocaml.
Modified:
llvm/trunk/bindings/ocaml/llvm/llvm_ocaml.c
Modified: llvm/trunk/bindings/ocaml/llvm/llvm_ocaml.c
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/bindings/ocaml/llvm/llvm_ocaml.c?rev=97368&r1=97367&r2=97368&view=diff
==============================================================================
--- llvm/trunk/bindings/ocaml/llvm/llvm_ocaml.c (original)
+++ llvm/trunk/bindings/ocaml/llvm/llvm_ocaml.c Sat Feb 27 23:51:16 2010
@@ -978,7 +978,7 @@
}
/* llbuilder -> llbasicblock */
-CAMLprim LLVMBasicBlockRef llvm_insertion_block(LLVMBuilderRef B) {
+CAMLprim LLVMBasicBlockRef llvm_insertion_block(value B) {
LLVMBasicBlockRef InsertBlock = LLVMGetInsertBlock(Builder_val(B));
if (!InsertBlock)
raise_not_found();
@@ -986,9 +986,8 @@
}
/* llvalue -> string -> llbuilder -> unit */
-CAMLprim value llvm_insert_into_builder(LLVMValueRef I, value Name,
- LLVMBuilderRef B) {
- LLVMInsertIntoBuilderWithName(B, I, String_val(Name));
+CAMLprim value llvm_insert_into_builder(LLVMValueRef I, value Name, value B) {
+ LLVMInsertIntoBuilderWithName(Builder_val(B), I, String_val(Name));
return Val_unit;
}
More information about the llvm-commits
mailing list