Function uleb128::uleb128_u32_len[][src]

pub fn uleb128_u32_len(n: u32) -> usize
Expand description

Get the length of the unsigned 32-bit integer’s unsigned LEB128 representation in bytes.

Examples

use uleb128::uleb128_u32_len;

assert_eq!(1, uleb128_u32_len(127));
assert_eq!(2, uleb128_u32_len(128));