]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
[3.13] Docs: use boolean constants for returning boolean value (GH-133325) (GH-133761)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Fri, 9 May 2025 14:19:23 +0000 (16:19 +0200)
committerGitHub <noreply@github.com>
Fri, 9 May 2025 14:19:23 +0000 (14:19 +0000)
(cherry picked from commit 076004ae5461cf3a7fe248a38e28afff33acdd14)

Co-authored-by: Yongzi Li <1538321957@qq.com>
Doc/library/stdtypes.rst
Doc/library/string.rst

index 97e023f30bef9eaf38c7bf2ee4bb7ccd958340c0..0936be0caaf9038544ba70d3dd5f09c72a131655 100644 (file)
@@ -1876,7 +1876,7 @@ expression support in the :mod:`re` module).
 
 .. method:: str.isprintable()
 
-   Return true if all characters in the string are printable, false if it
+   Return ``True`` if all characters in the string are printable, ``False`` if it
    contains at least one non-printable character.
 
    Here "printable" means the character is suitable for :func:`repr` to use in
index 1cad5f3ff225f3ff9b5b0c78d050b707e7b6baf8..e0ecb3799eabf70d5c66c643dc86daf721ff4aed 100644 (file)
@@ -845,7 +845,7 @@ these rules.  The methods of :class:`Template` are:
 
    .. method:: is_valid()
 
-      Returns false if the template has invalid placeholders that will cause
+      Returns ``False`` if the template has invalid placeholders that will cause
       :meth:`substitute` to raise :exc:`ValueError`.
 
       .. versionadded:: 3.11