[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | Jianzhou Zhao <jianzhou@s...> |
| Subject: | Re: [Caml-list] OCaml Int64 <-> C int64_t |
On Wed, Aug 18, 2010 at 1:36 PM, Mathias Kende <mathias@kende.fr> wrote:
> Le mercredi 18 août 2010 à 13:28 -0400, Jianzhou Zhao a écrit :
>> But mlvalues.h does not declare them to use. How can I
>> convert int64 to value?
>
> caml_copy_int64 is declared in <caml/alloc.h>. There is no Val_int64
> macro because int64 values are heap objects which must be allocated (the
> Val_... macros are mostly just static_cast).
Does caml_copy_int64 do all I want?
int64_t C_fun();
CAMLprim value stub()
{
return (caml_copy_int64 (C_fun()));
}
Do we still need I64_of_intnat? It is not included in <caml/alloc.h>
or other headers.
>
> Mathias
>
>
--
Jianzhou