Skip to content

Commit d15f47d

Browse files
authored
[3.10] [doc] Fix typos found using codespell (GH-28744) (GH-28758)
1 parent 325e464 commit d15f47d

File tree

12 files changed

+16
-16
lines changed

12 files changed

+16
-16
lines changed

Doc/c-api/call.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ Object Calling API
185185
Various functions are available for calling a Python object.
186186
Each converts its arguments to a convention supported by the called object –
187187
either *tp_call* or vectorcall.
188-
In order to do as litle conversion as possible, pick one that best fits
188+
In order to do as little conversion as possible, pick one that best fits
189189
the format of data you have available.
190190
191191
The following table summarizes the available functions;

Doc/c-api/init_config.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ There are two kinds of configuration:
2222
* The :ref:`Isolated Configuration <init-isolated-conf>` can be used to embed
2323
Python into an application. It isolates Python from the system. For example,
2424
environments variables are ignored, the LC_CTYPE locale is left unchanged and
25-
no signal handler is registred.
25+
no signal handler is registered.
2626

2727
The :c:func:`Py_RunMain` function can be used to write a customized Python
2828
program.
@@ -696,7 +696,7 @@ PyConfig
696696
* Otherwise, use the :term:`locale encoding`:
697697
``nl_langinfo(CODESET)`` result.
698698
699-
At Python statup, the encoding name is normalized to the Python codec
699+
At Python startup, the encoding name is normalized to the Python codec
700700
name. For example, ``"ANSI_X3.4-1968"`` is replaced with ``"ascii"``.
701701
702702
See also the :c:member:`~PyConfig.filesystem_errors` member.

Doc/faq/design.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -714,7 +714,7 @@ Why don't generators support the with statement?
714714
For technical reasons, a generator used directly as a context manager
715715
would not work correctly. When, as is most common, a generator is used as
716716
an iterator run to completion, no closing is needed. When it is, wrap
717-
it as "contextlib.closing(generator)" in the 'with' statment.
717+
it as "contextlib.closing(generator)" in the 'with' statement.
718718

719719

720720
Why are colons required for the if/while/def/class statements?

Doc/library/ast.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1920,7 +1920,7 @@ and classes for traversing abstract syntax trees:
19201920
If source contains a null character ('\0'), :exc:`ValueError` is raised.
19211921

19221922
.. warning::
1923-
Note that succesfully parsing souce code into an AST object doesn't
1923+
Note that successfully parsing source code into an AST object doesn't
19241924
guarantee that the source code provided is valid Python code that can
19251925
be executed as the compilation step can raise further :exc:`SyntaxError`
19261926
exceptions. For instance, the source ``return 42`` generates a valid

Doc/library/base64.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ The modern interface provides:
152152
This version does not allow the digit 0 (zero) to the letter O (oh) and digit
153153
1 (one) to either the letter I (eye) or letter L (el) mappings, all these
154154
characters are included in the Extended Hex Alphabet and are not
155-
interchangable.
155+
interchangeable.
156156

157157
.. versionadded:: 3.10
158158

Doc/library/fileinput.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ You can control how files are opened by providing an opening hook via the
5050
*openhook* parameter to :func:`fileinput.input` or :class:`FileInput()`. The
5151
hook must be a function that takes two arguments, *filename* and *mode*, and
5252
returns an accordingly opened file-like object. If *encoding* and/or *errors*
53-
are specified, they will be passed to the hook as aditional keyword arguments.
53+
are specified, they will be passed to the hook as additional keyword arguments.
5454
This module provides a :func:`hook_compressed` to support compressed files.
5555

5656
The following function is the primary interface of this module:

Doc/library/importlib.metadata.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@ function::
255255
Package distributions
256256
---------------------
257257

258-
A convience method to resolve the distribution or
258+
A convenience method to resolve the distribution or
259259
distributions (in the case of a namespace package) for top-level
260260
Python packages or modules::
261261

Doc/library/test.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1249,7 +1249,7 @@ The :mod:`test.support.threading_helper` module provides support for threading t
12491249
Context manager catching :class:`threading.Thread` exception using
12501250
:func:`threading.excepthook`.
12511251

1252-
Attributes set when an exception is catched:
1252+
Attributes set when an exception is caught:
12531253

12541254
* ``exc_type``
12551255
* ``exc_value``
@@ -1458,7 +1458,7 @@ The :mod:`test.support.os_helper` module provides support for os tests.
14581458
.. function:: unlink(filename)
14591459

14601460
Call :func:`os.unlink` on *filename*. On Windows platforms, this is
1461-
wrapped with a wait loop that checks for the existence fo the file.
1461+
wrapped with a wait loop that checks for the existence of the file.
14621462

14631463

14641464
:mod:`test.support.import_helper` --- Utilities for import tests

Doc/library/types.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,7 @@ Standard names are defined for the following types:
243243

244244
.. note::
245245
A future version of Python may stop setting this attribute by default.
246-
To guard against this potential change, preferrably read from the
246+
To guard against this potential change, preferably read from the
247247
:attr:`__spec__` attribute instead or use
248248
``getattr(module, "__loader__", None)`` if you explicitly need to use
249249
this attribute.
@@ -268,7 +268,7 @@ Standard names are defined for the following types:
268268

269269
.. note::
270270
A future version of Python may stop setting this attribute by default.
271-
To guard against this potential change, preferrably read from the
271+
To guard against this potential change, preferably read from the
272272
:attr:`__spec__` attribute instead or use
273273
``getattr(module, "__package__", None)`` if you explicitly need to use
274274
this attribute.

Doc/tools/rstlint.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ def hide_comments(lines):
165165
"""Tool to remove comments from given lines.
166166
167167
It yields empty lines in place of comments, so line numbers are
168-
still meaningfull.
168+
still meaningful.
169169
"""
170170
in_multiline_comment = False
171171
for line in lines:

Doc/using/configure.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -550,7 +550,7 @@ Built-in modules have no ``__file__`` attribute::
550550
File "<stdin>", line 1, in <module>
551551
AttributeError: module 'sys' has no attribute '__file__'
552552

553-
Other C extensins are built as dynamic libraires, like the ``_asyncio`` module.
553+
Other C extensins are built as dynamic libraries, like the ``_asyncio`` module.
554554
They are built with the ``Py_BUILD_CORE_MODULE`` macro defined.
555555
Example on Linux x86-64::
556556

Doc/whatsnew/3.10.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1579,7 +1579,7 @@ Deprecated
15791579
15801580
* Currently Python accepts numeric literals immediately followed by keywords,
15811581
for example ``0in x``, ``1or x``, ``0if 1else 2``. It allows confusing
1582-
and ambigious expressions like ``[0x1for x in y]`` (which can be
1582+
and ambiguous expressions like ``[0x1for x in y]`` (which can be
15831583
interpreted as ``[0x1 for x in y]`` or ``[0x1f or x in y]``). Starting in
15841584
this release, a deprecation warning is raised if the numeric literal is
15851585
immediately followed by one of keywords :keyword:`and`, :keyword:`else`,
@@ -1916,7 +1916,7 @@ Changes in the Python API
19161916
if the *globals* dictionary has no ``"__builtins__"`` key, rather than using
19171917
``{"None": None}`` as builtins: same behavior as :func:`eval` and
19181918
:func:`exec` functions. Defining a function with ``def function(...): ...``
1919-
in Python is not affected, globals cannot be overriden with this syntax: it
1919+
in Python is not affected, globals cannot be overridden with this syntax: it
19201920
also inherits the current builtins.
19211921
(Contributed by Victor Stinner in :issue:`42990`.)
19221922

0 commit comments

Comments
 (0)