License | BSD-style |
---|---|
Maintainer | Vincent Hanquez <vincent@snarc.org> |
Stability | experimental |
Portability | Good |
Safe Haskell | None |
Language | Haskell2010 |
Fast serialization primitives for integer using raw pointers (little endian)
Documentation
i2osp :: Integer -> Ptr Word8 -> Int -> IO Int Source #
Fill a pointer with the little endian binary representation of an integer
If the room available ptrSz
is less than the number of bytes needed,
0 is returned. Likewise if a parameter is invalid, 0 is returned.
Returns the number of bytes written