Function mini_leb128::write_u64

source ·
pub fn write_u64<W>(writer: W, n: u64) -> Result<NonZeroUsize>where
W: Write,
Expand description

Encodes an unsigned 64-bit integer using LEB128.

Returns a NonZeroUsize that stores how many bytes it took to encode the integer.

Errors

Propagates any I/O errors originating from the writer. However, encoding the integer itself is infallible.