]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Docs: Fix broken reference `__getitem__` in `string.rst` (#103371)
authoryuki <drsuaimqjgar@gmail.com>
Sun, 9 Apr 2023 02:02:16 +0000 (11:02 +0900)
committerGitHub <noreply@github.com>
Sun, 9 Apr 2023 02:02:16 +0000 (07:32 +0530)
Doc/library/string.rst

index 5ada827328188dfa097df04aff4b43a5ffa54c78..f55074cc5827184d8f26c5c50e9e1f313ed13cba 100644 (file)
@@ -235,7 +235,7 @@ dictionary keys (e.g., the strings ``'10'`` or ``':-]'``) within a format string
 The *arg_name* can be followed by any number of index or
 attribute expressions. An expression of the form ``'.name'`` selects the named
 attribute using :func:`getattr`, while an expression of the form ``'[index]'``
-does an index lookup using :func:`__getitem__`.
+does an index lookup using :meth:`~object.__getitem__`.
 
 .. versionchanged:: 3.1
    The positional argument specifiers can be omitted for :meth:`str.format`,