Result!(size_t, BitpackError): bytes written. Failures leave
dst untouched: INVALID_WIDTH, INSUFFICIENT_CAPACITY (context == 0), INVALID_VALUE (context = value index).
Result!(size_t, BitpackError) packUint32(scope const(uint)[] values,
ubyte width, return scope ubyte[] dst) @safe pure nothrow @nogcPacks unsigned 32-bit values at width bits each (LSB-first).
values | the values to pack (each must be < 2^width). |
width | bits per value, 1..32. |
dst | caller-provided output buffer (≥ packedSize bytes). |
Result!(size_t, BitpackError): bytes written. Failures leave
dst untouched: INVALID_WIDTH, INSUFFICIENT_CAPACITY (context == 0), INVALID_VALUE (context = value index).