[Rpm-maint] [PATCH 03/15] Generalize type object initialization to work with both Python 2.* and Python 3.*

Panu Matilainen pmatilai at redhat.com
Mon Oct 19 08:08:09 UTC 2009


On Thu, 15 Oct 2009, David Malcolm wrote:

> The layout of PyVarObject changed between python 2 and python 3, and 
> this leads to the existing code for all of the various PyTypeObject 
> initializers failing to compile with python 3
>
> Change the way we initialize these structs to use PyVarObject_HEAD_INIT 
> directly, rather than merely PyObject_HEAD_INIT, so that it compiles 
> cleanly with both major versions of Python

Same as with Py_TYPE() - breaks Python < 2.6 but easily worked around so
applied.

 	- Panu -


More information about the Rpm-maint mailing list