summaryrefslogtreecommitdiffstats
path: root/Doc/c-api
diff options
context:
space:
mode:
authorEric Snow <ericsnowcurrently@gmail.com>2017-05-23 02:46:40 (GMT)
committerGitHub <noreply@github.com>2017-05-23 02:46:40 (GMT)
commite377416c10eb0bf055b0728cdcdc4488fdfd3b5f (patch)
tree26dac18a3dfca605d0d09a61603b70a7d635e3b5 /Doc/c-api
parent93fc20b73eea3da0b6305aaee951e5dd22d5c408 (diff)
downloadcpython-e377416c10eb0bf055b0728cdcdc4488fdfd3b5f.zip
cpython-e377416c10eb0bf055b0728cdcdc4488fdfd3b5f.tar.gz
cpython-e377416c10eb0bf055b0728cdcdc4488fdfd3b5f.tar.bz2
bpo-29102: Add a unique ID to PyInterpreterState. (#1639)
Diffstat (limited to 'Doc/c-api')
-rw-r--r--Doc/c-api/init.rst8
1 files changed, 8 insertions, 0 deletions
diff --git a/Doc/c-api/init.rst b/Doc/c-api/init.rst
index 56cf77a..ca7636b 100644
--- a/Doc/c-api/init.rst
+++ b/Doc/c-api/init.rst
@@ -821,6 +821,14 @@ been created.
:c:func:`PyThreadState_Clear`.
+.. c:function:: PY_INT64_T PyInterpreterState_GetID(PyInterpreterState *interp)
+
+ Return the interpreter's unique ID. If there was any error in doing
+ so then -1 is returned and an error is set.
+
+ .. versionadded:: 3.7
+
+
.. c:function:: PyObject* PyThreadState_GetDict()
Return a dictionary in which extensions can store thread-specific state