mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
Vladimir Marangozov's long-awaited malloc restructuring.
For more comments, read the patches@python.org archives. For documentation read the comments in mymalloc.h and objimpl.h. (This is not exactly what Vladimir posted to the patches list; I've made a few changes, and Vladimir sent me a fix in private email for a problem that only occurs in debug mode. I'm also holding back on his change to main.c, which seems unnecessary to me.)
This commit is contained in:
parent
2808b744e8
commit
b18618dab7
73 changed files with 658 additions and 407 deletions
|
@ -273,7 +273,7 @@ PyCursesScreen_New(arg)
|
|||
PyFileObject *in_fo;
|
||||
PyFileObject *out_fo;
|
||||
PyCursesScreenObject *xp;
|
||||
xp = PyObject_NEW(PyCursesScreenObject, &PyCursesScreen_Type);
|
||||
xp = PyObject_New(PyCursesScreenObject, &PyCursesScreen_Type);
|
||||
if (xp == NULL)
|
||||
return NULL;
|
||||
return (PyObject *)xp;
|
||||
|
@ -289,7 +289,7 @@ PyCursesWindow_New(win)
|
|||
{
|
||||
PyCursesWindowObject *wo;
|
||||
|
||||
wo = PyObject_NEW(PyCursesWindowObject, &PyCursesWindow_Type);
|
||||
wo = PyObject_New(PyCursesWindowObject, &PyCursesWindow_Type);
|
||||
if (wo == NULL)
|
||||
return NULL;
|
||||
wo->win = win;
|
||||
|
@ -303,7 +303,7 @@ PyCursesWindow_Dealloc(wo)
|
|||
{
|
||||
if (wo->win != stdscr)
|
||||
delwin(wo->win);
|
||||
PyMem_DEL(wo);
|
||||
PyObject_Del(wo);
|
||||
}
|
||||
|
||||
static PyObject *
|
||||
|
@ -1125,7 +1125,7 @@ PyCursesPad_New(pad)
|
|||
WINDOW *pad;
|
||||
{
|
||||
PyCursesPadObject *po;
|
||||
po = PyObject_NEW(PyCursesPadObject, &PyCursesPad_Type);
|
||||
po = PyObject_New(PyCursesPadObject, &PyCursesPad_Type);
|
||||
if (po == NULL)
|
||||
return NULL;
|
||||
po->pad = pad;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue