Closed tr11 closed 10 years ago
Hi, Sorry for the lag I was on vacation. Thanks for your PR.
I have the impression that your patch won't work on Python <3, as the PyBytes_*
functions only seem to exist in Python >= 3.
Could you fix that?
Sorry, I didn't get your comment. I tested this patch on Python 2.6, 2.7, 3.2 and 3.3. Are you referring to another version?
@steeve it would be nice if this could be merged. Are you asking about Python 3.0? That version is not really used widely, and its use is discouraged by the Python maintainers.
Ooops sorry I just saw your comment.
I'm under the impression that _PyBytes_Resize
doesn't exist on Python < 3.
Am I wrong? You seem to have tested it though.
The issue is 3 months old. This is embarrassing, sorry.
@steeve, I'm not sure about previous Python versions, but at least for 2.6 and 2.7 the following is in the bytesobject.h
header file in the python includes:
#define _PyBytes_Resize _PyString_Resize
so at least for those versions, the macro _PyBytes_Resize
is defined. Not sure about the existence of this macro for python <2.6, though.
Sorry for the lag. Looks good to me. Merged!
This pull request adds support for Python 3. It should fix issue #7.