This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author vstinner
Recipients Josh.Ayers, ezio.melotti, python-dev, serhiy.storchaka, vstinner
Date 2014-10-10.07:36:18
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1412926579.05.0.117223014148.issue22580@psf.upfronthosting.co.za>
In-reply-to
Content
> It looks rather as a bug in C code. There is no need to return Py_ssize_t instead of int.

Oh yes, you're right. A Py_ssize_t to return -1, 0 or 1 is overkill :-)

But PyUnicode_Tailmatch() is now part of the stable ABI, the inefficient return type is not a bug import enough to break the ABI in Python 3.5.

In Python 2.7, I see for example that the function is implemented with tailmatch() which returns an int, and PyUnicode_Tailmatch() casts it to Py_ssize_t.
History
Date User Action Args
2014-10-10 07:36:19vstinnersetrecipients: + vstinner, ezio.melotti, python-dev, serhiy.storchaka, Josh.Ayers
2014-10-10 07:36:19vstinnersetmessageid: <1412926579.05.0.117223014148.issue22580@psf.upfronthosting.co.za>
2014-10-10 07:36:19vstinnerlinkissue22580 messages
2014-10-10 07:36:18vstinnercreate