fix: long != intnat

`sizeof long` is not necessarily identical to `sizeof intnat` (e.g. on windows64, long is 32bit and and intnat 64bit). The changes follow the prototypes in `caml/custom.h`.