]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Fix link in programming FAQ.
authorBerker Peksag <berker.peksag@gmail.com>
Wed, 1 Jun 2016 20:54:33 +0000 (13:54 -0700)
committerBerker Peksag <berker.peksag@gmail.com>
Wed, 1 Jun 2016 20:54:33 +0000 (13:54 -0700)
The example actually uses the sort method of list object.

Doc/faq/programming.rst

index 8157124cda422ba56b64c603d96dff4a37bde95f..b2ad7a7cc400d3e27d68214558e90a6b728738ae 100644 (file)
@@ -1312,7 +1312,7 @@ I want to do a complicated sort: can you do a Schwartzian Transform in Python?
 
 The technique, attributed to Randal Schwartz of the Perl community, sorts the
 elements of a list by a metric which maps each element to its "sort value". In
-Python, use the ``key`` argument for the :func:`sort()` function::
+Python, use the ``key`` argument for the :meth:`list.sort` method::
 
    Isorted = L[:]
    Isorted.sort(key=lambda s: int(s[10:15]))