mirror of
https://github.com/python/cpython.git
synced 2025-11-24 20:30:18 +00:00
Add usage note.
This commit is contained in:
parent
0c9050c25d
commit
7d74effc67
1 changed files with 3 additions and 2 deletions
|
|
@ -49,8 +49,9 @@ The :mod:`functools` module defines the following functions:
|
||||||
Since a dictionary is used to cache results, the positional and keyword
|
Since a dictionary is used to cache results, the positional and keyword
|
||||||
arguments to the function must be hashable.
|
arguments to the function must be hashable.
|
||||||
|
|
||||||
If *maxsize* is set to None, the LRU feature is disabled and the cache
|
If *maxsize* is set to None, the LRU feature is disabled and the cache can
|
||||||
can grow without bound.
|
grow without bound. The LRU feature performs best when *maxsize* is a
|
||||||
|
power-of-two.
|
||||||
|
|
||||||
If *typed* is set to True, function arguments of different types will be
|
If *typed* is set to True, function arguments of different types will be
|
||||||
cached separately. For example, ``f(3)`` and ``f(3.0)`` will be treated
|
cached separately. For example, ``f(3)`` and ``f(3.0)`` will be treated
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue