use typenames equivalent to
authorGabor Greif <ggreif@gmail.com>
Thu, 20 Sep 2007 10:20:34 +0000 (10:20 +0000)
committerGabor Greif <ggreif@gmail.com>
Thu, 20 Sep 2007 10:20:34 +0000 (10:20 +0000)
(u)intval, because latter are not
present in older caml/mlvalues.h
(e.g. 2004/07/07, 1.48.6.1)

Using this as a workaround for now,
until --without-ocaml works
or we settle on a better solution

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42160 91177308-0d34-0410-b5e6-96231b3b80d8

bindings/ocaml/llvm/llvm_ocaml.c

index c297a5f3e6f7688580b4a91f67915b2b99351ab1..80d7f737bab49d0d957aa3af122eefbf7f064489 100644 (file)
@@ -273,9 +273,9 @@ CAMLprim value llvm_make_int_constant(value IntTy, value N, value SExt) {
   /* GCC warns if we use the ternary operator. */
   unsigned long long N2;
   if (Bool_val(SExt))
-    N2 = (intnat) Int_val(N);
+    N2 = (value) Int_val(N);
   else
-    N2 = (uintnat) Int_val(N);
+    N2 = (mlsize_t) Int_val(N);
   
   return (value) LLVMGetIntConstant((LLVMTypeRef) IntTy, N2, Bool_val(SExt));
 }