pub fn universal_decode_number(bytes: &[u8], signed: bool) -> u64
Expand description
Handles both top-encoding and nested-encoding, signed and unsigned, of any length.
The result needs to be validated to not exceed limits and then cast to the desired type.
No generics here, we avoid monomorphization to make the SC binary as small as possible.