fn sliceCast(bytes: []u8, comptime NewInt: type, comptime new_endian: Endian, bit_offset: u3, old_len: usize) PackedIntSliceEndian(NewInt, new_endian)

Recasts a packed slice to a version with elements of type NewInt and endianness new_endian. Slice will begin at bit_offset within bytes and the new length will be automatically calculated from old_len using the sizes of the current integer type and NewInt.

Parameters

bytes: []u8,
NewInt: type,
new_endian: Endian,
bit_offset: u3,
old_len: usize,