diff options
author | jlhutch <jlhutch@gmail.com> | 2015-03-17 12:13:35 -0500 |
---|---|---|
committer | jlhutch <jlhutch@gmail.com> | 2015-03-17 12:13:35 -0500 |
commit | 5e24a4b4d141ff7b6426d771ada3801665132e5c (patch) | |
tree | 1432257d45f402258283397a5e7d521d27cc6d46 | |
parent | 221dd259f5c34562c835611d1cf62384b9019da4 (diff) | |
parent | 35eda410d422066cc470901d5bea231f66fcd855 (diff) | |
download | pylru-5e24a4b4d141ff7b6426d771ada3801665132e5c.tar.gz |
Merge pull request #12 from iho/patch-1
Make cache available from outer space.
-rw-r--r-- | README.txt | 2 | ||||
-rw-r--r-- | pylru.py | 1 |
2 files changed, 3 insertions, 0 deletions
@@ -209,5 +209,7 @@ PyLRU also provides a function decorator:: return x*x # Now results of the square function are cached for future lookup. + # You can get full access to cache via square.cache . + @@ -529,4 +529,5 @@ class lrudecorator(object): value = func(*args, **kwargs) self.cache[key] = value return value + wrapped.cache = self.cache return wrapped |