English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
OCaml Int64 <-> C int64_t
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Jianzhou Zhao <jianzhou@s...>
Subject: OCaml Int64 <-> C int64_t

To convert between OCaml Int64 and C Integer, I think uint64_t or
int64_t can be the target C type. Int64_val is the macro converting
OCaml value to int64, I failed to find the macro for the other
direction under ./byterun. ./byterun/ints.c defines operations on
int64, caml_copy_int64(I64_of_intnat(..)) seems to be working for such
conversion? But mlvalues.h does not declare them to use. How can I
convert int64 to value?