From: Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> Date: Tue, 16 Dec 2025 11:50:02 +0000 (+0100) Subject: [3.13] Correct Glossary key function example to use str.casefold instead of str.lower... X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1baa3152228b3734515de4465d0c88822ae211ec;p=thirdparty%2FPython%2Fcpython.git [3.13] Correct Glossary key function example to use str.casefold instead of str.lower (GH-140316) (#142806) Co-authored-by: Cameron Beck <94604154+cbkinase@users.noreply.github.com> --- diff --git a/Doc/glossary.rst b/Doc/glossary.rst index bdb44009e812..3cf62f493251 100644 --- a/Doc/glossary.rst +++ b/Doc/glossary.rst @@ -767,7 +767,7 @@ Glossary :func:`itertools.groupby`. There are several ways to create a key function. For example. the - :meth:`str.lower` method can serve as a key function for case insensitive + :meth:`str.casefold` method can serve as a key function for case insensitive sorts. Alternatively, a key function can be built from a :keyword:`lambda` expression such as ``lambda r: (r[0], r[2])``. Also, :func:`operator.attrgetter`, :func:`operator.itemgetter`, and