]> granicus.if.org Git - python/commitdiff
Root variable is not changed.
authorRaymond Hettinger <python@rcn.com>
Sat, 17 Mar 2012 00:08:37 +0000 (17:08 -0700)
committerRaymond Hettinger <python@rcn.com>
Sat, 17 Mar 2012 00:08:37 +0000 (17:08 -0700)
Lib/functools.py

index 19b7613918121b90256e7cea6639ff85e3dd9de7..fec4b9e7036aa2c2a71281436c6edebfd9f609d9 100644 (file)
@@ -223,7 +223,7 @@ def lru_cache(maxsize=100, typed=False):
 
         def cache_clear():
             """Clear the cache and cache statistics"""
-            nonlocal hits, misses, root
+            nonlocal hits, misses
             with lock:
                 cache.clear()
                 root[:] = [root, root, None, None]