From 1b6726732c63d69f45f80deabe8435c2a6347db4 Mon Sep 17 00:00:00 2001 From: Georg Brandl Date: Fri, 17 Feb 2006 08:56:33 +0000 Subject: Bug #1432350: arrayobject should use PyObject_VAR_HEAD --- Doc/api/newtypes.tex | 2 +- Modules/arraymodule.c | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/Doc/api/newtypes.tex b/Doc/api/newtypes.tex index a95f836..bfce26c 100644 --- a/Doc/api/newtypes.tex +++ b/Doc/api/newtypes.tex @@ -188,7 +188,7 @@ These macros are used in the definition of \ctype{PyObject} and instance. This macro always expands to: \begin{verbatim} PyObject_HEAD - int ob_size; + Py_ssize_t ob_size; \end{verbatim} Note that \csimplemacro{PyObject_HEAD} is part of the expansion, and that its own expansion varies depending on the definition of diff --git a/Modules/arraymodule.c b/Modules/arraymodule.c index dffb2e7..4152bad 100644 --- a/Modules/arraymodule.c +++ b/Modules/arraymodule.c @@ -29,8 +29,7 @@ struct arraydescr { }; typedef struct arrayobject { - PyObject_HEAD - Py_ssize_t ob_size; + PyObject_VAR_HEAD char *ob_item; Py_ssize_t allocated; struct arraydescr *ob_descr; -- cgit v0.12