mirror of
https://github.com/python/cpython.git
synced 2025-12-04 00:30:19 +00:00
bpo-40024: Update C extension modules to use PyModule_AddType() (GH-19119)
Update _asyncio, _bz2, _csv, _curses, _datetime, _io, _operator, _pickle, _queue, blake2, multibytecodec and overlapped C extension modules to use PyModule_AddType().
This commit is contained in:
parent
15e5024d04
commit
37fcbb65d4
12 changed files with 66 additions and 133 deletions
|
|
@ -4740,7 +4740,8 @@ PyInit__curses(void)
|
|||
SetDictInt("KEY_MAX", KEY_MAX);
|
||||
}
|
||||
|
||||
Py_INCREF(&PyCursesWindow_Type);
|
||||
PyModule_AddObject(m, "window", (PyObject *)&PyCursesWindow_Type);
|
||||
if (PyModule_AddType(m, &PyCursesWindow_Type) < 0) {
|
||||
return NULL;
|
||||
}
|
||||
return m;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue