Fix incorrect uses of an ocaml llbuilder without extracting it from ocaml.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@97368 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Erick Tryzelaar 2010-02-28 05:51:16 +00:00
parent d2b4aff4bc
commit 628b76ecb3

View File

@ -978,7 +978,7 @@ CAMLprim value llvm_position_builder(value Pos, value B) {
}
/* 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 @@ CAMLprim LLVMBasicBlockRef llvm_insertion_block(LLVMBuilderRef B) {
}
/* 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;
}