pub fn encode(value: usize, buf: &mut [u8]) -> usize
Encodes a usize into a varint and writes it into the provided buffer. Returns the number of bytes written.