diff options
Diffstat (limited to 'numpy/core/src/multiarray/textreading/stream_pyobject.c')
-rw-r--r-- | numpy/core/src/multiarray/textreading/stream_pyobject.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/numpy/core/src/multiarray/textreading/stream_pyobject.c b/numpy/core/src/multiarray/textreading/stream_pyobject.c index 6f84ff01d..3832ee84a 100644 --- a/numpy/core/src/multiarray/textreading/stream_pyobject.c +++ b/numpy/core/src/multiarray/textreading/stream_pyobject.c @@ -4,11 +4,12 @@ * single line of a file. */ +#define PY_SSIZE_T_CLEAN +#include <Python.h> + #include <stdio.h> #include <stdlib.h> -#define PY_SSIZE_T_CLEAN -#include <Python.h> #define NPY_NO_DEPRECATED_API NPY_API_VERSION #define _MULTIARRAYMODULE #include "numpy/arrayobject.h" @@ -41,7 +42,7 @@ typedef struct { * * NOTE: Steals a reference to `str` (although usually returns it unmodified). */ -static NPY_INLINE PyObject * +static inline PyObject * process_stringlike(PyObject *str, const char *encoding) { if (PyBytes_Check(str)) { @@ -63,7 +64,7 @@ process_stringlike(PyObject *str, const char *encoding) } -static NPY_INLINE void +static inline void buffer_info_from_unicode(PyObject *str, char **start, char **end, int *kind) { Py_ssize_t length = PyUnicode_GET_LENGTH(str); |