Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
442c6691
Commit
442c6691
authored
Dec 01, 2010
by
Raymond Hettinger
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Doc and docstring nits.
parent
027140e6
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
2 deletions
+6
-2
Doc/library/functools.rst
Doc/library/functools.rst
+4
-0
Lib/functools.py
Lib/functools.py
+2
-2
No files found.
Doc/library/functools.rst
View file @
442c6691
...
...
@@ -91,6 +91,10 @@ The :mod:`functools` module defines the following functions:
.. versionadded:: 3.2
.. seealso::
Recipe for a `plain cache without the LRU feature
<http://code.activestate.com/recipes/577479-simple-caching-decorator/>`_.
.. decorator:: total_ordering
...
...
Lib/functools.py
View file @
442c6691
...
...
@@ -121,9 +121,9 @@ def lru_cache(maxsize=100):
Arguments to the cached function must be hashable.
View the cache statistics named tuple (
maxsize, size, hits, misses
) with
View the cache statistics named tuple (
hits, misses, maxsize, currsize
) with
f.cache_info(). Clear the cache and statistics with f.cache_clear().
A
nd a
ccess the underlying function with f.__wrapped__.
Access the underlying function with f.__wrapped__.
See: http://en.wikipedia.org/wiki/Cache_algorithms#Least_Recently_Used
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment