Properly downcast from size_t/Py_ssize_t in a few places.
Properly downcast from size_t/Py_ssize_t in a few places.

sk-/python2.7-type-annotator,sk-/python2.7-type-annotator,sk-/python2.7-type-annotator