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

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

index 61d39a6671caed5c2ab949df16993f36d9476e6b..1d9a655c7664ea2b0c259bdc3ecf2dbdfccc5f1c 100644 (file)
@@ -2012,7 +2012,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 b44d98819b6998bd0b83e6755cd102ed9661b526..c4012483a52f730a63980a71ea370134b947db0c 100644 (file)
@@ -858,7 +858,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