We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4c56995 commit 265b9bcCopy full SHA for 265b9bc
include/pybind11/detail/non_limited_api.h
@@ -15,11 +15,12 @@
15
#include <dlfcn.h> // `dladdr` and friends.
16
#endif
17
18
-#ifdef Py_LIMITED_API
+#if !defined(PYBIND11_NONLIMITEDAPI_ONCE) && defined(Py_LIMITED_API)
19
+#define PYBIND11_NONLIMITEDAPI_ONCE
20
typedef struct _heaptypeobject PyHeapTypeObject;
21
typedef struct _typeobject PyTypeObject;
-typedef struct { double real; double imag; } Py_complex;
22
typedef struct PyConfig PyConfig;
23
+typedef struct { double real; double imag; } Py_complex;
24
25
// We must not use this in our own API below, because the definitions are different in different Python versions.
26
// Instead we provide our own type `Py_buffer_` below for use in our own API.
0 commit comments