@@ -1287,7 +1287,7 @@ All of the following functions must be called after :c:func:`Py_Initialize`.
12871287 function does not steal any references to *exc *. To prevent naive misuse, you
12881288 must write your own C extension to call this. Must be called with the GIL held.
12891289 Returns the number of thread states modified; this is normally one, but will be
1290- zero if the thread id isn't found. If *exc * is :const: ` NULL `, the pending
1290+ zero if the thread id isn't found. If *exc * is `` NULL ` `, the pending
12911291 exception (if any) for the thread is cleared. This raises no exceptions.
12921292
12931293 .. versionchanged:: 3.7
@@ -1566,32 +1566,32 @@ Python-level trace functions in previous versions.
15661566 The type of the trace function registered using :c:func: `PyEval_SetProfile ` and
15671567 :c:func: `PyEval_SetTrace `. The first parameter is the object passed to the
15681568 registration function as *obj *, *frame * is the frame object to which the event
1569- pertains, *what * is one of the constants :const : `PyTrace_CALL `,
1570- :const: `PyTrace_EXCEPTION `, :const: `PyTrace_LINE `, :const : `PyTrace_RETURN `,
1571- :const: `PyTrace_C_CALL `, :const: `PyTrace_C_EXCEPTION `, :const : `PyTrace_C_RETURN `,
1572- or :const : `PyTrace_OPCODE `, and *arg * depends on the value of *what *:
1573-
1574- +------------------------------+----------------------------------------+
1575- | Value of *what * | Meaning of *arg * |
1576- +==============================+========================================+
1577- | :const : `PyTrace_CALL ` | Always :c:data: `Py_None `. |
1578- +------------------------------+----------------------------------------+
1579- | :const : `PyTrace_EXCEPTION ` | Exception information as returned by |
1580- | | :func: `sys.exc_info `. |
1581- +------------------------------+----------------------------------------+
1582- | :const : `PyTrace_LINE ` | Always :c:data: `Py_None `. |
1583- +------------------------------+----------------------------------------+
1584- | :const : `PyTrace_RETURN ` | Value being returned to the caller, |
1585- | | or ``NULL `` if caused by an exception. |
1586- +------------------------------+----------------------------------------+
1587- | :const : `PyTrace_C_CALL ` | Function object being called. |
1588- +------------------------------+----------------------------------------+
1589- | :const : `PyTrace_C_EXCEPTION ` | Function object being called. |
1590- +------------------------------+----------------------------------------+
1591- | :const : `PyTrace_C_RETURN ` | Function object being called. |
1592- +------------------------------+----------------------------------------+
1593- | :const : `PyTrace_OPCODE ` | Always :c:data: `Py_None `. |
1594- +------------------------------+----------------------------------------+
1569+ pertains, *what * is one of the constants :c:data : `PyTrace_CALL `,
1570+ :c:data: `PyTrace_EXCEPTION `, :c:data: `PyTrace_LINE `, :c:data : `PyTrace_RETURN `,
1571+ :c:data: `PyTrace_C_CALL `, :c:data: `PyTrace_C_EXCEPTION `, :c:data : `PyTrace_C_RETURN `,
1572+ or :c:data : `PyTrace_OPCODE `, and *arg * depends on the value of *what *:
1573+
1574+ +------------------------------- +----------------------------------------+
1575+ | Value of *what * | Meaning of *arg * |
1576+ +=============================== +========================================+
1577+ | :c:data : `PyTrace_CALL ` | Always :c:data: `Py_None `. |
1578+ +------------------------------- +----------------------------------------+
1579+ | :c:data : `PyTrace_EXCEPTION ` | Exception information as returned by |
1580+ | | :func: `sys.exc_info `. |
1581+ +------------------------------- +----------------------------------------+
1582+ | :c:data : `PyTrace_LINE ` | Always :c:data: `Py_None `. |
1583+ +------------------------------- +----------------------------------------+
1584+ | :c:data : `PyTrace_RETURN ` | Value being returned to the caller, |
1585+ | | or ``NULL `` if caused by an exception. |
1586+ +------------------------------- +----------------------------------------+
1587+ | :c:data : `PyTrace_C_CALL ` | Function object being called. |
1588+ +------------------------------- +----------------------------------------+
1589+ | :c:data : `PyTrace_C_EXCEPTION ` | Function object being called. |
1590+ +------------------------------- +----------------------------------------+
1591+ | :c:data : `PyTrace_C_RETURN ` | Function object being called. |
1592+ +------------------------------- +----------------------------------------+
1593+ | :c:data : `PyTrace_OPCODE ` | Always :c:data: `Py_None `. |
1594+ +------------------------------- +----------------------------------------+
15951595
15961596.. c :var :: int PyTrace_CALL
15971597
@@ -1658,8 +1658,8 @@ Python-level trace functions in previous versions.
16581658 function as its first parameter, and may be any Python object, or ``NULL ``. If
16591659 the profile function needs to maintain state, using a different value for *obj *
16601660 for each thread provides a convenient and thread-safe place to store it. The
1661- profile function is called for all monitored events except :const : `PyTrace_LINE `
1662- :const: `PyTrace_OPCODE ` and :const : `PyTrace_EXCEPTION `.
1661+ profile function is called for all monitored events except :c:data : `PyTrace_LINE `
1662+ :c:data: `PyTrace_OPCODE ` and :c:data : `PyTrace_EXCEPTION `.
16631663
16641664 See also the :func: `sys.setprofile ` function.
16651665
@@ -1672,8 +1672,8 @@ Python-level trace functions in previous versions.
16721672 :c:func: `PyEval_SetProfile `, except the tracing function does receive line-number
16731673 events and per-opcode events, but does not receive any event related to C function
16741674 objects being called. Any trace function registered using :c:func: `PyEval_SetTrace `
1675- will not receive :const: `PyTrace_C_CALL `, :const : `PyTrace_C_EXCEPTION ` or
1676- :const : `PyTrace_C_RETURN ` as a value for the *what * parameter.
1675+ will not receive :c:data: `PyTrace_C_CALL `, :c:data : `PyTrace_C_EXCEPTION ` or
1676+ :c:data : `PyTrace_C_RETURN ` as a value for the *what * parameter.
16771677
16781678 See also the :func: `sys.settrace ` function.
16791679
0 commit comments