Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Fix pybuffer.h
  • Loading branch information
vstinner committed Feb 23, 2022
commit a36cec059b0a090d348d7ed006cd2c674053cd78
8 changes: 4 additions & 4 deletions Include/pybuffer.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@
extern "C" {
#endif

// Forward declaration to be able to include pybuffer.h before object.h:
// pybuffer.h uses PyObject and object.h uses Py_buffer.
typedef struct _object PyObject;

#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x030b0000

/* === New Buffer API ============================================
Expand All @@ -17,10 +21,6 @@ extern "C" {
*
*/

// Forward declaration to be able to include pybuffer.h before object.h:
// pybuffer.h uses PyObject and object.h uses Py_buffer.
typedef struct _object PyObject;

typedef struct {
void *buf;
PyObject *obj; /* owned reference */
Expand Down