Alexandre Vassalotti <alexan...@peadrop.com> added the comment: Here's an updated patch.
- Renamed tobytes() to to_bytes() and frombytes() to from_bytes(). - Moved the changes to pickle to a different patch. - Made the NULL-checks more consistent with the rest of long's code. - Fixed the type check of the `length' parameter of to_bytes() to use PyIndex_Check() instead of PyLong_Check(). ---------- dependencies: +Move the special-case for integer objects out of PyBytes_FromObject. Added file: http://bugs.python.org/file15333/long_and_bytes_conversion-3.diff _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue1023290> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com