From e523487d50e6ee3384bac3011f7c7e5dc3be9f55 Mon Sep 17 00:00:00 2001 From: Inada Naoki Date: Tue, 27 Oct 2026 18:47:20 +0900 Subject: [PATCH] Docs: Fix indentation that produced unintended definition lists and block quotes (GH-160740) * Fix documentation markup for translation * Fix more documentation markup for translation (cherry picked from commit 085b291748cb6edb12f39c7e9baaf207dac9c80d) Co-authored-by: Inada Naoki --- Doc/c-api/call.rst | 18 +++++++++--------- Doc/howto/functional.rst | 2 +- Doc/library/asyncio-eventloop.rst | 2 +- Doc/library/fractions.rst | 2 +- Doc/library/time.rst | 2 +- Doc/library/tkinter.font.rst | 6 +++--- Doc/library/unittest.rst | 2 +- Doc/library/xml.etree.elementtree.rst | 8 ++++---- Doc/whatsnew/2.2.rst | 2 +- Doc/whatsnew/2.4.rst | 4 ++-- Doc/whatsnew/3.12.rst | 12 ++++++------ 11 files changed, 30 insertions(+), 30 deletions(-) diff --git a/Doc/c-api/call.rst b/Doc/c-api/call.rst index 9838879a528934a..101318597723c9e 100644 --- a/Doc/c-api/call.rst +++ b/Doc/c-api/call.rst @@ -81,17 +81,17 @@ This is a pointer to a function with the following signature: - *callable* is the object being called. - *args* is a C array consisting of the positional arguments followed by the - values of the keyword arguments. - This can be *NULL* if there are no arguments. + values of the keyword arguments. + This can be *NULL* if there are no arguments. - *nargsf* is the number of positional arguments plus possibly the - :c:macro:`PY_VECTORCALL_ARGUMENTS_OFFSET` flag. - To get the actual number of positional arguments from *nargsf*, - use :c:func:`PyVectorcall_NARGS`. + :c:macro:`PY_VECTORCALL_ARGUMENTS_OFFSET` flag. + To get the actual number of positional arguments from *nargsf*, + use :c:func:`PyVectorcall_NARGS`. - *kwnames* is a tuple containing the names of the keyword arguments; - in other words, the keys of the kwargs dict. - These names must be strings (instances of ``str`` or a subclass) - and they must be unique. - If there are no keyword arguments, then *kwnames* can instead be *NULL*. + in other words, the keys of the kwargs dict. + These names must be strings (instances of ``str`` or a subclass) + and they must be unique. + If there are no keyword arguments, then *kwnames* can instead be *NULL*. .. c:macro:: PY_VECTORCALL_ARGUMENTS_OFFSET diff --git a/Doc/howto/functional.rst b/Doc/howto/functional.rst index f2ff5edeb733d7f..8e1a8ce4cc6f344 100644 --- a/Doc/howto/functional.rst +++ b/Doc/howto/functional.rst @@ -628,7 +628,7 @@ Two of Python's built-in functions, :func:`map` and :func:`filter` duplicate the features of generator expressions: :func:`map(f, iterA, iterB, ...) ` returns an iterator over the sequence - ``f(iterA[0], iterB[0]), f(iterA[1], iterB[1]), f(iterA[2], iterB[2]), ...``. +``f(iterA[0], iterB[0]), f(iterA[1], iterB[1]), f(iterA[2], iterB[2]), ...``. >>> def upper(s): ... return s.upper() diff --git a/Doc/library/asyncio-eventloop.rst b/Doc/library/asyncio-eventloop.rst index 74a4b344714235c..99c795b04fa6d69 100644 --- a/Doc/library/asyncio-eventloop.rst +++ b/Doc/library/asyncio-eventloop.rst @@ -1537,7 +1537,7 @@ Allows customizing how exceptions are handled in the event loop. * 'source_traceback' (optional): Traceback of the source; * 'handle_traceback' (optional): Traceback of the handle; * 'asyncgen' (optional): Asynchronous generator that caused - the exception. + the exception. .. note:: diff --git a/Doc/library/fractions.rst b/Doc/library/fractions.rst index b02e7b5b641136d..1672504304b1ed6 100644 --- a/Doc/library/fractions.rst +++ b/Doc/library/fractions.rst @@ -106,7 +106,7 @@ a single number, or from a string. .. versionchanged:: 3.12 :class:`Fraction` instances now support float-style formatting, with presentation types ``"e"``, ``"E"``, ``"f"``, ``"F"``, ``"g"``, ``"G"`` - and ``"%""``. + and ``"%"``. .. versionchanged:: 3.13 Formatting of :class:`Fraction` instances without a presentation type diff --git a/Doc/library/time.rst b/Doc/library/time.rst index d7ca0628c662ea0..992122e8e8e80bb 100644 --- a/Doc/library/time.rst +++ b/Doc/library/time.rst @@ -486,7 +486,7 @@ Functions | | | | +-----------+------------------------------------------------+-------+ | ``%f`` | Microseconds as a decimal number | \(1) | - | | [000000,999999]. | | + | | [000000,999999]. | | | | | | +-----------+------------------------------------------------+-------+ | ``%H`` | Hour (24-hour clock) as a decimal number | | diff --git a/Doc/library/tkinter.font.rst b/Doc/library/tkinter.font.rst index 947207724ab0409..1ac8bf4290e48c7 100644 --- a/Doc/library/tkinter.font.rst +++ b/Doc/library/tkinter.font.rst @@ -94,13 +94,13 @@ The different font weights and slants are: Options include: *ascent* - distance between baseline and highest point that a - character of the font can occupy + character of the font can occupy *descent* - distance between baseline and lowest point that a - character of the font can occupy + character of the font can occupy *linespace* - minimum vertical separation necessary between any two - characters of the font that ensures no vertical overlap between lines. + characters of the font that ensures no vertical overlap between lines. *fixed* - 1 if font is fixed-width else 0 diff --git a/Doc/library/unittest.rst b/Doc/library/unittest.rst index 7afcdb368a3562e..745be80119b1d29 100644 --- a/Doc/library/unittest.rst +++ b/Doc/library/unittest.rst @@ -994,7 +994,7 @@ Test cases | ` | with minimum *level* | | +---------------------------------------------------------+--------------------------------------+------------+ | :meth:`assertNoLogs(logger, level) | The ``with`` block does not log on | 3.10 | - | ` | *logger* with minimum *level* | | + | ` | *logger* with minimum *level* | | +---------------------------------------------------------+--------------------------------------+------------+ .. method:: assertRaises(exception, callable, *args, **kwds) diff --git a/Doc/library/xml.etree.elementtree.rst b/Doc/library/xml.etree.elementtree.rst index 8112f6ec1bbe930..c595fc0974a9d66 100644 --- a/Doc/library/xml.etree.elementtree.rst +++ b/Doc/library/xml.etree.elementtree.rst @@ -561,13 +561,13 @@ Functions - *with_comments*: set to true to include comments (default: false) - *strip_text*: set to true to strip whitespace before and after text content - (default: false) + (default: false) - *rewrite_prefixes*: set to true to replace namespace prefixes by "n{number}" - (default: false) + (default: false) - *qname_aware_tags*: a set of qname aware tag names in which prefixes - should be replaced in text content (default: empty) + should be replaced in text content (default: empty) - *qname_aware_attrs*: a set of qname aware attribute names in which prefixes - should be replaced in text content (default: empty) + should be replaced in text content (default: empty) - *exclude_attrs*: a set of attribute names that should not be serialised - *exclude_tags*: a set of tag names that should not be serialised diff --git a/Doc/whatsnew/2.2.rst b/Doc/whatsnew/2.2.rst index 856be5ecfa56ad3..5c69e473af6d5b5 100644 --- a/Doc/whatsnew/2.2.rst +++ b/Doc/whatsnew/2.2.rst @@ -1082,7 +1082,7 @@ code, none of the changes described here will affect you very much. * Rename :c:macro:`!Py_TPFLAGS_GC` to :c:macro:`Py_TPFLAGS_HAVE_GC`. * Use :c:func:`PyObject_GC_New` or :c:func:`PyObject_GC_NewVar` to allocate - objects, and :c:func:`PyObject_GC_Del` to deallocate them. + objects, and :c:func:`PyObject_GC_Del` to deallocate them. * Rename :c:func:`!PyObject_GC_Init` to :c:func:`PyObject_GC_Track` and :c:func:`!PyObject_GC_Fini` to :c:func:`PyObject_GC_UnTrack`. diff --git a/Doc/whatsnew/2.4.rst b/Doc/whatsnew/2.4.rst index 87c7b6b17477b50..ae3e9ed4646eeda 100644 --- a/Doc/whatsnew/2.4.rst +++ b/Doc/whatsnew/2.4.rst @@ -1015,8 +1015,8 @@ complete list of changes, or look through the CVS logs for all the details. * Chinese (ROC): big5, cp950 * Japanese: cp932, euc-jis-2004, euc-jp, euc-jisx0213, iso-2022-jp, - iso-2022-jp-1, iso-2022-jp-2, iso-2022-jp-3, iso-2022-jp-ext, iso-2022-jp-2004, - shift-jis, shift-jisx0213, shift-jis-2004 + iso-2022-jp-1, iso-2022-jp-2, iso-2022-jp-3, iso-2022-jp-ext, iso-2022-jp-2004, + shift-jis, shift-jisx0213, shift-jis-2004 * Korean: cp949, euc-kr, johab, iso-2022-kr diff --git a/Doc/whatsnew/3.12.rst b/Doc/whatsnew/3.12.rst index 71fe354b2c08f07..4e1df81c3407109 100644 --- a/Doc/whatsnew/3.12.rst +++ b/Doc/whatsnew/3.12.rst @@ -1993,17 +1993,17 @@ New Features to bypass reference counts, and related changes to the C-API: - ``_Py_IMMORTAL_REFCNT``: The reference count that defines an object - as immortal. + as immortal. - ``_Py_IsImmortal`` Checks if an object has the immortal reference count. - ``PyObject_HEAD_INIT`` This will now initialize reference count to - ``_Py_IMMORTAL_REFCNT`` when used with ``Py_BUILD_CORE``. + ``_Py_IMMORTAL_REFCNT`` when used with ``Py_BUILD_CORE``. - ``SSTATE_INTERNED_IMMORTAL`` An identifier for interned unicode objects - that are immortal. + that are immortal. - ``SSTATE_INTERNED_IMMORTAL_STATIC`` An identifier for interned unicode - objects that are immortal and static + objects that are immortal and static - ``sys.getunicodeinternedsize`` This returns the total number of unicode - objects that have been interned. This is now needed for :file:`refleak.py` to - correctly track reference counts and allocated blocks + objects that have been interned. This is now needed for :file:`refleak.py` to + correctly track reference counts and allocated blocks (Contributed by Eddie Elizondo in :gh:`84436`.)