On Fri, 30 May 2003 nobu.nokada / softhome.net wrote:

> > Yes, but this should work then
> >
> >   s = [large_bignum_or_really_any_int].pack("N(*)")
> >   num = s.unpack("N(#{s.length})").first
> >   # now num == large_bitnum_or_really_any_int
> >
> > ?
>
> By analogy with "a*", IMHO, it should fill least necessary
> bytes (or words?).
>
Yes, I agree. Bytes.

> But I don't guess variable length integer packing is so useful.
> If the range were really unpredictable, BER might be better.
>
It is useful in for example cryptography which is IMHO and important area
to support. I think we should have it.

Regards,

Robert