[ocaml-ctypes] Bigarray typing problem

Jeremy Yallop yallop at gmail.com
Sat Dec 7 22:34:26 GMT 2013


On 5 December 2013 14:13, Daniel Bünzli <daniel.buenzli at erratique.ch> wrote:
> That being said maybe what feels odd in that particular case is that ctypes has:
>
>   val uint16_t : uint16 typ
>
> and not
>
>   val uint16_t : int typ
>
> i.e. it "disagrees" with bigarrays.

Yes, it's a little unfortunate.  The reason is that ctypes aims to
support platforms where int is 16 bits (which is permitted by C)
whereas bigarray is written under the assumption that int is at least
32 bits.


More information about the Ctypes mailing list