Reconcile C API with docs

This fixes #5286 and results from discussion on that issue.
I didn't know there was a NPY_INTP_FMT macro -- I'll use that instead