mirror of
https://github.com/python/cpython.git
synced 2025-08-02 16:13:13 +00:00
Don't initialize tp_type statically, it won't work on Windows. Spotted
by Thomas Heller (patch 459442).
This commit is contained in:
parent
418c3b1e26
commit
1062e706e5
1 changed files with 1 additions and 1 deletions
|
@ -164,7 +164,7 @@ class ObjectDefinition(GeneratorGroup):
|
||||||
Output()
|
Output()
|
||||||
Output("%sPyTypeObject %s = {", sf, self.typename)
|
Output("%sPyTypeObject %s = {", sf, self.typename)
|
||||||
IndentLevel()
|
IndentLevel()
|
||||||
Output("PyObject_HEAD_INIT(&PyType_Type)")
|
Output("PyObject_HEAD_INIT(NULL)")
|
||||||
Output("0, /*ob_size*/")
|
Output("0, /*ob_size*/")
|
||||||
Output("\"%s\", /*tp_name*/", self.name)
|
Output("\"%s\", /*tp_name*/", self.name)
|
||||||
Output("sizeof(%s), /*tp_basicsize*/", self.objecttype)
|
Output("sizeof(%s), /*tp_basicsize*/", self.objecttype)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue