mirror of
https://github.com/python/cpython.git
synced 2025-07-19 09:15:34 +00:00
bpo-39573: Add Py_SET_TYPE() function (GH-18394)
Add Py_SET_TYPE() function to set the type of an object.
This commit is contained in:
parent
daa9756cb6
commit
d2ec81a8c9
24 changed files with 77 additions and 48 deletions
|
@ -78,6 +78,6 @@ PyTypeObject pysqlite_PrepareProtocolType= {
|
|||
extern int pysqlite_prepare_protocol_setup_types(void)
|
||||
{
|
||||
pysqlite_PrepareProtocolType.tp_new = PyType_GenericNew;
|
||||
Py_TYPE(&pysqlite_PrepareProtocolType)= &PyType_Type;
|
||||
Py_SET_TYPE(&pysqlite_PrepareProtocolType, &PyType_Type);
|
||||
return PyType_Ready(&pysqlite_PrepareProtocolType);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue