Safe Haskell | None |
---|---|
Language | Haskell98 |
Loading and storing integers directly from/to memory buffers.
Loading
:: Ptr Word8 | Buffer holding digits. |
-> Int | Length of buffer. |
-> IO (Maybe (Int, Int)) | Int read, and length of digits. |
Load an ASCII Int
from a foreign buffer,
returning the value and number of characters read.
:: Ptr Word8 | Buffer holding digits. |
-> Int# | Length of buffer. |
-> (#Int#, Int#, Int##) | Convert success?, value, length read. |
Like loadInt
, but via unboxed types.
:: (Int# -> Int#) | Function to get a byte from the source. |
-> Int# | Length of buffer |
-> (#Int#, Int#, Int##) | Convert success?, value, length read. |
Like loadInt#
, but use the given function to get characters
from the input buffer.