Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bpo-1635741: Port _string module to multi-phase init #22148

Merged
merged 1 commit into from
Sep 8, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Port the ``_string`` extension module to the multi-phase initialization API
(:pep:`489`).
14 changes: 5 additions & 9 deletions Objects/unicodeobject.c
Original file line number Diff line number Diff line change
Expand Up @@ -16243,20 +16243,16 @@ static PyMethodDef _string_methods[] = {

static struct PyModuleDef _string_module = {
PyModuleDef_HEAD_INIT,
"_string",
PyDoc_STR("string helper module"),
0,
_string_methods,
NULL,
NULL,
NULL,
NULL
.m_name = "_string",
.m_doc = PyDoc_STR("string helper module"),
.m_size = 0,
.m_methods = _string_methods,
};

PyMODINIT_FUNC
PyInit__string(void)
{
return PyModule_Create(&_string_module);
return PyModuleDef_Init(&_string_module);
}


Expand Down