bytestring-builder-varword-0.1.0.0: Variable-length integer encoding

Safe HaskellNone
LanguageHaskell2010

Data.ByteString.Builder.Prim.VarWord

Description

Implementations of BoundedPrim for several variable-length integer encodings. Rather than use these directly, consider the higher level Data.ByteString.Builder.VarNum Builder interface.

Synopsis

Documentation

varWordBe :: forall a. (Bits a, Integral a, Storable a) => BoundedPrim a Source #

BoundedPrim for big-endian (most significant chunk first) variable length encoding

denseVarWordBe :: forall a. (Bits a, Integral a, Storable a) => BoundedPrim a Source #

BoundedPrim for big-endian (most significant chunk first) variable length encoding where the continuation bit is also reused to pack information slightly more densely.

varWordLe :: forall a. (Bits a, Integral a, Storable a) => BoundedPrim a Source #

BoundedPrim for little-endian (least significant chunk first) variable length encoding