This is an archive of the discontinued Mercurial Phabricator instance.

sha1dc: use proper string functions on Python 2/3
ClosedPublic

Authored by indygreg on Jan 14 2020, 8:54 PM.

Details

Summary

PyString_FromStringAndSize doesn't exist on Python 3: we need
to use PyUnicode_FromStringAndSize.

The extension now compiles without warnings on Python 2 and 3.

Diff Detail

Repository
rHG Mercurial
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

indygreg created this revision.Jan 14 2020, 8:54 PM
pulkit accepted this revision.Jan 15 2020, 7:09 AM
This revision is now accepted and ready to land.Jan 15 2020, 7:09 AM
This revision was automatically updated to reflect the committed changes.