caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* [Caml-list] Getting some C values over to the OCaml side correctly
@ 2016-09-25  8:02 Edgar A
  2016-09-25  8:40 ` David Allsopp
  0 siblings, 1 reply; 5+ messages in thread
From: Edgar A @ 2016-09-25  8:02 UTC (permalink / raw)
  To: caml-list

Greetings, 

I have some C values that I want to get over to the OCaml side using the FFI. 

Specifically I have `uint32_t`, `intptr_t` and `int32_t` and I’m not sure how to get it over to the OCaml side correctly. 

Would the uint32_t be expressed as a Int32.t? Do I really need to put an integer as block just to get it to the OCaml side, because of the 31 bit integers on the OCaml side right? 

Been looking for examples but can’t find any, example code greatly appreciated, the C side and the ml side please. 

Thank you, 
Edgar (Algebr) 




^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2016-10-06  9:19 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-25  8:02 [Caml-list] Getting some C values over to the OCaml side correctly Edgar A
2016-09-25  8:40 ` David Allsopp
2016-09-25  8:43   ` Edgar A
2016-09-25 12:28     ` David Allsopp
2016-10-06  9:19       ` Goswin von Brederlow

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).