Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4adf01c

Browse files
Issue #19795: Improved more markups of True/False.
1 parent 1883542 commit 4adf01c

14 files changed

Lines changed: 23 additions & 23 deletions

Doc/c-api/number.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -278,5 +278,5 @@ Number Protocol
278278
279279
.. c:function:: int PyIndex_Check(PyObject *o)
280280
281-
Returns True if *o* is an index integer (has the nb_index slot of the
282-
tp_as_number structure filled in).
281+
Returns ``1`` if *o* is an index integer (has the nb_index slot of the
282+
tp_as_number structure filled in), and ``0`` otherwise.

Doc/library/asyncio-eventloop.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -346,7 +346,7 @@ Creating connections
346346

347347
* *reuse_address* tells the kernel to reuse a local socket in
348348
TIME_WAIT state, without waiting for its natural timeout to
349-
expire. If not specified will automatically be set to True on
349+
expire. If not specified will automatically be set to ``True`` on
350350
UNIX.
351351

352352
* *reuse_port* tells the kernel to allow this endpoint to be bound to the
@@ -424,7 +424,7 @@ Creating listening connections
424424

425425
* *reuse_address* tells the kernel to reuse a local socket in
426426
TIME_WAIT state, without waiting for its natural timeout to
427-
expire. If not specified will automatically be set to True on
427+
expire. If not specified will automatically be set to ``True`` on
428428
UNIX.
429429

430430
* *reuse_port* tells the kernel to allow this endpoint to be bound to the

Doc/library/asyncio-task.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ Future
245245

246246
.. method:: done()
247247

248-
Return True if the future is done.
248+
Return ``True`` if the future is done.
249249

250250
Done means either that a result / exception are available, or that the
251251
future was cancelled.
@@ -562,7 +562,7 @@ Task functions
562562
All futures must share the same event loop. If all the tasks are done
563563
successfully, the returned future's result is the list of results (in the
564564
order of the original sequence, not necessarily the order of results
565-
arrival). If *return_exceptions* is True, exceptions in the tasks are
565+
arrival). If *return_exceptions* is true, exceptions in the tasks are
566566
treated the same as successful results, and gathered in the result list;
567567
otherwise, the first raised exception will be immediately propagated to the
568568
returned future.

Doc/library/ctypes.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1358,7 +1358,7 @@ details, consult the :manpage:`dlopen(3)` manpage. On Windows, *mode* is
13581358
ignored. On posix systems, RTLD_NOW is always added, and is not
13591359
configurable.
13601360

1361-
The *use_errno* parameter, when set to True, enables a ctypes mechanism that
1361+
The *use_errno* parameter, when set to true, enables a ctypes mechanism that
13621362
allows accessing the system :data:`errno` error number in a safe way.
13631363
:mod:`ctypes` maintains a thread-local copy of the systems :data:`errno`
13641364
variable; if you call foreign functions created with ``use_errno=True`` then the
@@ -1369,7 +1369,7 @@ The function :func:`ctypes.get_errno` returns the value of the ctypes private
13691369
copy, and the function :func:`ctypes.set_errno` changes the ctypes private copy
13701370
to a new value and returns the former value.
13711371

1372-
The *use_last_error* parameter, when set to True, enables the same mechanism for
1372+
The *use_last_error* parameter, when set to true, enables the same mechanism for
13731373
the Windows error code which is managed by the :func:`GetLastError` and
13741374
:func:`SetLastError` Windows API functions; :func:`ctypes.get_last_error` and
13751375
:func:`ctypes.set_last_error` are used to request and change the ctypes private
@@ -1579,7 +1579,7 @@ type and the argument types of the function.
15791579

15801580
The returned function prototype creates functions that use the standard C
15811581
calling convention. The function will release the GIL during the call. If
1582-
*use_errno* is set to True, the ctypes private copy of the system
1582+
*use_errno* is set to true, the ctypes private copy of the system
15831583
:data:`errno` variable is exchanged with the real :data:`errno` value before
15841584
and after the call; *use_last_error* does the same for the Windows error
15851585
code.

Doc/library/functools.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ The :mod:`functools` module defines the following functions:
5656
grow without bound. The LRU feature performs best when *maxsize* is a
5757
power-of-two.
5858

59-
If *typed* is set to True, function arguments of different types will be
59+
If *typed* is set to true, function arguments of different types will be
6060
cached separately. For example, ``f(3)`` and ``f(3.0)`` will be treated
6161
as distinct calls with distinct results.
6262

Doc/library/io.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -537,7 +537,7 @@ Raw File I/O
537537
The *name* can be one of two things:
538538

539539
* a character string or :class:`bytes` object representing the path to the
540-
file which will be opened. In this case closefd must be True (the default)
540+
file which will be opened. In this case closefd must be ``True`` (the default)
541541
otherwise an error will be raised.
542542
* an integer representing the number of an existing OS-level file descriptor
543543
to which the resulting :class:`FileIO` object will give access. When the

Doc/library/logging.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ is the module's name in the Python package namespace.
318318
looking for handlers in this logger and its parents in the logger hierarchy.
319319
Returns ``True`` if a handler was found, else ``False``. The method stops searching
320320
up the hierarchy whenever a logger with the 'propagate' attribute set to
321-
False is found - that will be the last logger which is checked for the
321+
false is found - that will be the last logger which is checked for the
322322
existence of handlers.
323323

324324
.. versionadded:: 3.2

Doc/library/quopri.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ sending a graphics file.
5252

5353
Like :func:`encode`, except that it accepts a source :class:`bytes` and
5454
returns the corresponding encoded :class:`bytes`. By default, it sends a
55-
False value to *quotetabs* parameter of the :func:`encode` function.
55+
``False`` value to *quotetabs* parameter of the :func:`encode` function.
5656

5757

5858

Doc/library/ssl.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1387,7 +1387,7 @@ to speed up repeated connections from the same clients.
13871387
This setting doesn't apply to client sockets. You can also use the
13881388
:data:`OP_SINGLE_ECDH_USE` option to further improve security.
13891389

1390-
This method is not available if :data:`HAS_ECDH` is False.
1390+
This method is not available if :data:`HAS_ECDH` is ``False``.
13911391

13921392
.. versionadded:: 3.3
13931393

Doc/library/subprocess.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ compatibility with older versions, see the :ref:`call-function-trio` section.
6464
is automatically created with ``stdin=PIPE``, and the *stdin* argument may
6565
not be used as well.
6666

67-
If *check* is True, and the process exits with a non-zero exit code, a
67+
If *check* is true, and the process exits with a non-zero exit code, a
6868
:exc:`CalledProcessError` exception will be raised. Attributes of that
6969
exception hold the arguments, the exit code, and stdout and stderr if they
7070
were captured.

0 commit comments

Comments
 (0)