pub fn read_int<B: ByteSlice, T: FromPrimitive>(
    buf: B
) -> Result<(T, usize), Error>