projects
/
python
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cd9b5c2
)
Issue #16394: Note the tee() pure python equivalent is only a rough approximation.
author
Raymond Hettinger
<python@rcn.com>
Tue, 26 Apr 2016 07:10:00 +0000
(
00:10
-0700)
committer
Raymond Hettinger
<python@rcn.com>
Tue, 26 Apr 2016 07:10:00 +0000
(
00:10
-0700)
Doc/library/itertools.rst
patch
|
blob
|
history
diff --git
a/Doc/library/itertools.rst
b/Doc/library/itertools.rst
index 758e49b282a3cab901f24fea0f6fcad0f5aad0e2..8376f1a417a8cffcce48b9f8564668199a54c3ed 100644
(file)
--- a/
Doc/library/itertools.rst
+++ b/
Doc/library/itertools.rst
@@
-588,7
+588,10
@@
loops that truncate the stream.
.. function:: tee(iterable, n=2)
- Return *n* independent iterators from a single iterable. Equivalent to::
+ Return *n* independent iterators from a single iterable.
+
+ The following Python code helps explain what *tee* does (although the actual
+ implementation is more complex and uses only a single underlying FIFO queue)::
def tee(iterable, n=2):
it = iter(iterable)