]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Typing docs: fix typo in annotating tuples comment (#106048)
authorEamon Tracey <66919574+EamonTracey@users.noreply.github.com>
Fri, 23 Jun 2023 20:34:05 +0000 (16:34 -0400)
committerGitHub <noreply@github.com>
Fri, 23 Jun 2023 20:34:05 +0000 (21:34 +0100)
Doc/library/typing.rst

index 7458fa568b3253fe970a77127d2a7f73ce217d46..9771ba0a794b35651aea5084a8e0bf144abafde5 100644 (file)
@@ -362,8 +362,8 @@ the container will be of the same type. For example::
    # Type checker error: ``list`` only accepts a single type argument:
    y: list[int, str] = [1, 'foo']
 
-   # Type checker will infer that all keys in ``y`` are meant to be strings,
-   # and that all values in ``y`` are meant to be either strings or ints
+   # Type checker will infer that all keys in ``z`` are meant to be strings,
+   # and that all values in ``z`` are meant to be either strings or ints
    z: Mapping[str, str | int] = {}
 
 :class:`list` only accepts one type argument, so a type checker would emit an