Skip to content

gh-117764: Add signatures in the atexit module #117776

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

Merged
merged 1 commit into from
Apr 12, 2024
Merged
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
gh-117764: Add signatures in the atexit module
  • Loading branch information
serhiy-storchaka committed Apr 11, 2024
commit 2e386221553e17c7f0b92ffe2f75a19df7ce4009
15 changes: 10 additions & 5 deletions Modules/atexitmodule.c
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,8 @@ _PyAtExit_Call(PyInterpreterState *interp)


PyDoc_STRVAR(atexit_register__doc__,
"register(func, *args, **kwargs) -> func\n\
"register($module, func, /, *args, **kwargs)\n\
--\n\
\n\
Register a function to be executed upon normal program termination\n\
\n\
Expand Down Expand Up @@ -221,7 +222,8 @@ atexit_register(PyObject *module, PyObject *args, PyObject *kwargs)
}

PyDoc_STRVAR(atexit_run_exitfuncs__doc__,
"_run_exitfuncs() -> None\n\
"_run_exitfuncs($module, /)\n\
--\n\
\n\
Run all registered exit functions.\n\
\n\
Expand All @@ -236,7 +238,8 @@ atexit_run_exitfuncs(PyObject *module, PyObject *unused)
}

PyDoc_STRVAR(atexit_clear__doc__,
"_clear() -> None\n\
"_clear($module, /)\n\
--\n\
\n\
Clear the list of previously registered exit functions.");

Expand All @@ -248,7 +251,8 @@ atexit_clear(PyObject *module, PyObject *unused)
}

PyDoc_STRVAR(atexit_ncallbacks__doc__,
"_ncallbacks() -> int\n\
"_ncallbacks($module, /)\n\
--\n\
\n\
Return the number of registered exit functions.");

Expand All @@ -260,7 +264,8 @@ atexit_ncallbacks(PyObject *module, PyObject *unused)
}

PyDoc_STRVAR(atexit_unregister__doc__,
"unregister(func) -> None\n\
"unregister($module, func, /)\n\
--\n\
\n\
Unregister an exit function which was previously registered using\n\
atexit.register\n\
Expand Down