]> granicus.if.org Git - python/commit
Issue 7846: fnmatch cache can grow without bound
authorRaymond Hettinger <python@rcn.com>
Mon, 9 Aug 2010 02:07:15 +0000 (02:07 +0000)
committerRaymond Hettinger <python@rcn.com>
Mon, 9 Aug 2010 02:07:15 +0000 (02:07 +0000)
commit5b0c1e07ca169feced6d6458f80c2b9ccc6227e0
tree17ba65edefe013fcaf3edf8138dc6f38023445ca
parent44c6c155d6cc0d218decd250d84a238196be8daa
Issue 7846:  fnmatch cache can grow without bound

Updated to solution to use the functools.lru_cache().
Restores the API so that purge() is not needed
(because the cache never gets big).
Doc/library/fnmatch.rst
Lib/fnmatch.py
Lib/test/test_fnmatch.py