Skip to main content

decode_into

Function decode_into 

Source
pub unsafe fn decode_into<V: DictionaryView>(
    codes: &[Token],
    dict: V,
    out: &mut [MaybeUninit<u8>],
) -> usize
Expand description

Decode codes against dict into out, returning the bytes written. It over-reads a fixed 16 bytes per token, relying on the structural invariants guaranteed by DictionaryView. Each code is bounds-checked in the loop (a near-free, predicted-not-taken branch); an out-of-range code panics with InvalidColumn::CodeOutOfRange.

ยงSafety

out.len() >= decoded_len(codes, dict) + DECODE_PADDING.