summaryrefslogtreecommitdiffstats
path: root/Doc/api/api.tex
diff options
context:
space:
mode:
authorFred Drake <fdrake@acm.org>1998-01-26 19:16:27 (GMT)
committerFred Drake <fdrake@acm.org>1998-01-26 19:16:27 (GMT)
commitc6c921a4def19c9b44f1e1234b35f7fb0a609731 (patch)
treecb6201b35820eaf9f2444d67a50282861a5dd89c /Doc/api/api.tex
parent25f1722dd765826dc020d5e6ff6b89b0edaedbfd (diff)
downloadcpython-c6c921a4def19c9b44f1e1234b35f7fb0a609731.zip
cpython-c6c921a4def19c9b44f1e1234b35f7fb0a609731.tar.gz
cpython-c6c921a4def19c9b44f1e1234b35f7fb0a609731.tar.bz2
Py_AtExit(): Added brief note about the constraint on cleanup functions not
calling the Python API.
Diffstat (limited to 'Doc/api/api.tex')
-rw-r--r--Doc/api/api.tex15
1 files changed, 9 insertions, 6 deletions
diff --git a/Doc/api/api.tex b/Doc/api/api.tex
index 4e1a850..26fc104 100644
--- a/Doc/api/api.tex
+++ b/Doc/api/api.tex
@@ -542,12 +542,15 @@ calls the standard \C{} library function \code{exit(0)}.
\end{cfuncdesc}
\begin{cfuncdesc}{int}{Py_AtExit}{void (*func) ()}
-Register a cleanup function to be called by \code{Py_Finalize()}. The
-cleanup function will be called with no arguments and should return no
-value. At most 32 cleanup functions can be registered. When the
-registration is successful, \code{Py_AtExit} returns 0; on failure, it
-returns -1. The cleanup function registered last is called first.
-Each cleanup function will be called at most once.
+Register a cleanup function to be called by \cfunction{Py_Finalize()}.
+The cleanup function will be called with no arguments and should
+return no value. At most 32 cleanup functions can be registered.
+When the registration is successful, \cfunction{Py_AtExit()} returns
+\code{0}; on failure, it returns \code{-1}. The cleanup function
+registered last is called first. Each cleanup function will be called
+at most once. Since Python's internal finallization will have
+completed before the cleanup function, no Python APIs should be called
+by \var{func}.
\end{cfuncdesc}