[PATCH] OCaml bindings: fix Int_val used on Int64.t value
Peter Zotov
whitequark at whitequark.org
Thu Oct 31 19:13:21 PDT 2013
Hi sylvestre.ledru,
Bug exposed by unit tests I rewrote
http://llvm-reviews.chandlerc.com/D2084
Files:
bindings/ocaml/target/target_ocaml.c
Index: bindings/ocaml/target/target_ocaml.c
===================================================================
--- bindings/ocaml/target/target_ocaml.c
+++ bindings/ocaml/target/target_ocaml.c
@@ -92,7 +92,7 @@
/* DataLayout.t -> Llvm.lltype -> Int64.t -> int */
CAMLprim value llvm_element_at_offset(LLVMTargetDataRef TD, LLVMTypeRef Ty,
value Offset) {
- return Val_int(LLVMElementAtOffset(TD, Ty, Int_val(Offset)));
+ return Val_int(LLVMElementAtOffset(TD, Ty, Int64_val(Offset)));
}
/* DataLayout.t -> Llvm.lltype -> int -> Int64.t */
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D2084.1.patch
Type: text/x-patch
Size: 587 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20131031/d6626ef5/attachment.bin>
More information about the llvm-commits
mailing list