bpo-36769: Document that fnmatch.filter supports any kind of iterable… · python/cpython@e8d2264

Original file line numberDiff line numberDiff line change

@@ -75,7 +75,7 @@ patterns.

7575
7676

.. function:: filter(names, pattern)

7777
78-

Return the subset of the list of *names* that match *pattern*. It is the same as

78+

Construct a list from those elements of the iterable *names* that match *pattern*. It is the same as

7979

``[n for n in names if fnmatch(n, pattern)]``, but implemented more efficiently.

8080
8181