"Guido van Rossum" <[EMAIL PROTECTED]> wrote:
> Sounds good to me -- I don't have this need myself but it seems to fit
> well.  I'm looking forward to a patch. :-)

If I remember correctly, 2.5 was supposed to have binascii.long2b() and
binascii.b2long() which would have converted a long integer to a 2.x
string and vv, offering access to the underlying PyLong_AsString() and
PyLong_FromString() functions.  According to my Python 2.5 distribution
and the documentation, it didn't make it.

Note that there exists a patch against some 2.3 for the struct module
that implements a typecode for allowing the packing and unpacking of
arbitrarily lengthed integers, also offering access to the underlying
PyLong functions.  This would likely need to be updated for the post-2.5
struct module, if its functionality is desired.

 - Josiah


> On 11/17/06, Neil Schemenauer <[EMAIL PROTECTED]> wrote:
> > ----- Forwarded message from Antti Louko <[EMAIL PROTECTED]> -----
> >
> > Date: Fri, 17 Nov 2006 08:25:03 +0200
> > From: Antti Louko <[EMAIL PROTECTED]>
> > Subject: Python bytes object
> > To: [EMAIL PROTECTED]
> >
> > Python bytes object is useful.
> >
> > I would add bitwise logical operations. They would be most useful in
> > cryptographic and graphics operations.
> >
> > Also, encoding and decoding (long) integers in binary fromat to and from
> > bytes type would be useful. Currently, there is no way to efficiently
> > convert long integers to binary formats.
> >
> > Regards,
> >
> >         Antti Louko
> >
> > ----- End forwarded message -----
> > _______________________________________________
> > Python-3000 mailing list
> > Python-3000@python.org
> > http://mail.python.org/mailman/listinfo/python-3000
> > Unsubscribe: 
> > http://mail.python.org/mailman/options/python-3000/guido%40python.org
> >
> 
> 
> -- 
> --Guido van Rossum (home page: http://www.python.org/~guido/)
> _______________________________________________
> Python-3000 mailing list
> Python-3000@python.org
> http://mail.python.org/mailman/listinfo/python-3000
> Unsubscribe: 
> http://mail.python.org/mailman/options/python-3000/jcarlson%40uci.edu

_______________________________________________
Python-3000 mailing list
Python-3000@python.org
http://mail.python.org/mailman/listinfo/python-3000
Unsubscribe: 
http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com

Reply via email to