summaryrefslogtreecommitdiffstats
path: root/Doc/c-api/sys.rst
diff options
context:
space:
mode:
Diffstat (limited to 'Doc/c-api/sys.rst')
-rw-r--r--Doc/c-api/sys.rst18
1 files changed, 18 insertions, 0 deletions
diff --git a/Doc/c-api/sys.rst b/Doc/c-api/sys.rst
index 97717f5..cca8b7b 100644
--- a/Doc/c-api/sys.rst
+++ b/Doc/c-api/sys.rst
@@ -237,11 +237,21 @@ accessible to C code. They all work with the current interpreter thread's
.. c:function:: void PySys_AddWarnOption(const wchar_t *s)
+ This API is kept for backward compatibility: setting
+ :c:member:`PyConfig.warnoptions` should be used instead, see :ref:`Python
+ Initialization Configuration <init-config>`.
+
Append *s* to :data:`sys.warnoptions`. This function must be called prior
to :c:func:`Py_Initialize` in order to affect the warnings filter list.
+ .. deprecated:: 3.11
+
.. c:function:: void PySys_AddWarnOptionUnicode(PyObject *unicode)
+ This API is kept for backward compatibility: setting
+ :c:member:`PyConfig.warnoptions` should be used instead, see :ref:`Python
+ Initialization Configuration <init-config>`.
+
Append *unicode* to :data:`sys.warnoptions`.
Note: this function is not currently usable from outside the CPython
@@ -250,6 +260,8 @@ accessible to C code. They all work with the current interpreter thread's
called until enough of the runtime has been initialized to permit the
creation of Unicode objects.
+ .. deprecated:: 3.11
+
.. c:function:: void PySys_SetPath(const wchar_t *path)
Set :data:`sys.path` to a list object of paths found in *path* which should
@@ -294,12 +306,18 @@ accessible to C code. They all work with the current interpreter thread's
.. c:function:: void PySys_AddXOption(const wchar_t *s)
+ This API is kept for backward compatibility: setting
+ :c:member:`PyConfig.xoptions` should be used instead, see :ref:`Python
+ Initialization Configuration <init-config>`.
+
Parse *s* as a set of :option:`-X` options and add them to the current
options mapping as returned by :c:func:`PySys_GetXOptions`. This function
may be called prior to :c:func:`Py_Initialize`.
.. versionadded:: 3.2
+ .. deprecated:: 3.11
+
.. c:function:: PyObject *PySys_GetXOptions()
Return the current dictionary of :option:`-X` options, similarly to