[Python-checkins] cpython: Fix-up a comment

raymond.hettinger python-checkins at python.org
Sat Mar 31 11:19:42 CEST 2012


http://hg.python.org/cpython/rev/1c22c1109824
changeset: 76004:1c22c1109824
user: Raymond Hettinger <python at rcn.com>
date: Sat Mar 31 02:19:06 2012 -0700
summary:
 Fix-up a comment
files:
 Lib/functools.py | 5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/Lib/functools.py b/Lib/functools.py
--- a/Lib/functools.py
+++ b/Lib/functools.py
@@ -172,7 +172,7 @@
 cache = {}
 hits = misses = 0
 kwd_mark = (object(),) # separate positional and keyword args
- cache_get = cache.get # bound method to lookup key or return None
+ cache_get = cache.get # bound method to lookup a key or return None
 sentinel = object() # unique object used with cache_get
 _len = len # localize the global len() function
 lock = Lock() # because linkedlist updates aren't threadsafe
@@ -250,8 +250,7 @@
 # empty the oldest link and make it the new root
 root = root[NEXT]
 del cache[root[KEY]]
- root[KEY] = None
- root[RESULT] = None
+ root[KEY] = root[RESULT] = None
 misses += 1
 return result
 
-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /