Skip to content

Commit 5342ffc

Browse files
committed
clean up Doc/c-api/exceptions.rst
1 parent 1836f67 commit 5342ffc

3 files changed

Lines changed: 8 additions & 9 deletions

File tree

Doc/c-api/exceptions.rst

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -396,7 +396,7 @@ an error value).
396396
.. c:function:: int PyErr_ResourceWarning(PyObject *source, Py_ssize_t stack_level, const char *format, ...)
397397
398398
Function similar to :c:func:`PyErr_WarnFormat`, but *category* is
399-
:exc:`ResourceWarning` and it passes *source* to :func:`warnings.WarningMessage`.
399+
:exc:`ResourceWarning` and it passes *source* to :class:`!warnings.WarningMessage`.
400400
401401
.. versionadded:: 3.6
402402
@@ -732,7 +732,7 @@ Exception Classes
732732
This creates a class object derived from :exc:`Exception` (accessible in C as
733733
:c:data:`PyExc_Exception`).
734734
735-
The :attr:`__module__` attribute of the new class is set to the first part (up
735+
The :attr:`!__module__` attribute of the new class is set to the first part (up
736736
to the last dot) of the *name* argument, and the class name is set to the last
737737
part (after the last dot). The *base* argument can be used to specify alternate
738738
base classes; it can either be only one class or a tuple of classes. The *dict*
@@ -904,7 +904,7 @@ because the :ref:`call protocol <call>` takes care of recursion handling.
904904
905905
Marks a point where a recursive C-level call is about to be performed.
906906
907-
If :c:macro:`USE_STACKCHECK` is defined, this function checks if the OS
907+
If :c:macro:`!USE_STACKCHECK` is defined, this function checks if the OS
908908
stack overflowed using :c:func:`PyOS_CheckStack`. In this is the case, it
909909
sets a :exc:`MemoryError` and returns a nonzero value.
910910
@@ -1158,11 +1158,11 @@ These are compatibility aliases to :c:data:`PyExc_OSError`:
11581158
+-------------------------------------+----------+
11591159
| C Name | Notes |
11601160
+=====================================+==========+
1161-
| :c:data:`PyExc_EnvironmentError` | |
1161+
| :c:data:`!PyExc_EnvironmentError` | |
11621162
+-------------------------------------+----------+
1163-
| :c:data:`PyExc_IOError` | |
1163+
| :c:data:`!PyExc_IOError` | |
11641164
+-------------------------------------+----------+
1165-
| :c:data:`PyExc_WindowsError` | [2]_ |
1165+
| :c:data:`!PyExc_WindowsError` | [2]_ |
11661166
+-------------------------------------+----------+
11671167
11681168
.. versionchanged:: 3.3

Doc/c-api/sys.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,9 +98,9 @@ Operating System Utilities
9898
.. c:function:: int PyOS_CheckStack()
9999
100100
Return true when the interpreter runs out of stack space. This is a reliable
101-
check, but is only available when :c:macro:`USE_STACKCHECK` is defined (currently
101+
check, but is only available when :c:macro:`!USE_STACKCHECK` is defined (currently
102102
on certain versions of Windows using the Microsoft Visual C++ compiler).
103-
:c:macro:`USE_STACKCHECK` will be defined automatically; you should never
103+
:c:macro:`!USE_STACKCHECK` will be defined automatically; you should never
104104
change the definition in your own code.
105105
106106

Doc/tools/.nitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
# Keep lines sorted lexicographically to help avoid merge conflicts.
44

55
Doc/c-api/descriptor.rst
6-
Doc/c-api/exceptions.rst
76
Doc/c-api/float.rst
87
Doc/c-api/gcsupport.rst
98
Doc/c-api/init.rst

0 commit comments

Comments
 (0)