HORIZON HASKELLDocslts/ghc-9.10.x248f8f02026-10-05Search names, modules, packages, or :: a typeCtrl K

GHC 9.10.3 · lts/ghc-9.10.x · 248f8f0 · 2026-10-05

Modulebyte-order-0.1.3.1Haskell2010

Data.Primitive.ByteArray.LittleEndian

This is drop-in replacement for the read, write, and index functions present in Data.Primitive.ByteArray and Data.Primitive.ByteArray.Unaligned. While the functions from those modules use native byte order, the functions in this one use little-endian byte order (least significant byte first).

  • 6 values
  • Packagebyte-order-0.1.3.1
  • Exports6
  • LanguageHaskell2010
  • LicenceBSD-3-Clause
  • SourceLittleEndian.hs

Aligned

3 declarations
valueindexByteArray :: (Prim a, Bytes a) => ByteArray -> Int -> a
#

Read a primitive value from the byte array, interpreting the first byte as the least significant one. The offset is given in elements of type a rather than in bytes.

Unaligned

3 declarations