Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
`Python.h` must be included before including and standard library headers, if it's pulled in (which happens when you include numpy headers). Otherwise we see build warnings like: ``` 142/244] Compiling C object numpy/core/_multiarray_umath.cpython-311-x86_64-linux-gnu.so.p/src_multiarray_textreading_field_types.c.o In file included from /opt/hostedtoolcache/Python/3.11.0/x64/include/python3.11/Python.h:86, from ../numpy/core/include/numpy/npy_common.h:5, from ../numpy/core/include/numpy/ndarraytypes.h:4, from ../numpy/core/src/multiarray/textreading/field_types.h:9, from ../numpy/core/src/multiarray/textreading/field_types.c:1: /opt/hostedtoolcache/Python/3.11.0/x64/include/python3.11/cpython/pytime.h:208:60: warning: ‘struct timespec’ declared inside parameter list will not be visible outside of this definition or declaration 208 | PyAPI_FUNC(int) _PyTime_FromTimespec(_PyTime_t *tp, struct timespec *ts); | ^~~~~~~~ /opt/hostedtoolcache/Python/3.11.0/x64/include/python3.11/cpython/pytime.h:213:56: warning: ‘struct timespec’ declared inside parameter list will not be visible outside of this definition or declaration 213 | PyAPI_FUNC(int) _PyTime_AsTimespec(_PyTime_t t, struct timespec *ts); | ^~~~~~~~ /opt/hostedtoolcache/Python/3.11.0/x64/include/python3.11/cpython/pytime.h:217:63: warning: ‘struct timespec’ declared inside parameter list will not be visible outside of this definition or declaration 217 | PyAPI_FUNC(void) _PyTime_AsTimespec_clamp(_PyTime_t t, struct timespec *ts); | ^~~~~~~~ ```
- Loading branch information