summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2006-11-08 10:04:32 (GMT)
committerGeorg Brandl <georg@python.org>2006-11-08 10:04:32 (GMT)
commit3ed5c2a277fcc2da2b52aa923e32d267e4be0dd5 (patch)
tree98bd81ffc5f049b4ef7545e907f451a17d2a31a9
parent082f14b61c567f9f54fbfad69d5fb35857ead72c (diff)
downloadcpython-3ed5c2a277fcc2da2b52aa923e32d267e4be0dd5.zip
cpython-3ed5c2a277fcc2da2b52aa923e32d267e4be0dd5.tar.gz
cpython-3ed5c2a277fcc2da2b52aa923e32d267e4be0dd5.tar.bz2
Bug #1592533: rename variable in heapq doc example, to avoid shadowing
"sorted". (backport from rev. 52668)
-rw-r--r--Doc/lib/libheapq.tex8
1 files changed, 4 insertions, 4 deletions
diff --git a/Doc/lib/libheapq.tex b/Doc/lib/libheapq.tex
index eaf7051..5f3d8c5 100644
--- a/Doc/lib/libheapq.tex
+++ b/Doc/lib/libheapq.tex
@@ -76,14 +76,14 @@ Example of use:
>>> for item in data:
... heappush(heap, item)
...
->>> sorted = []
+>>> ordered = []
>>> while heap:
-... sorted.append(heappop(heap))
+... ordered.append(heappop(heap))
...
->>> print sorted
+>>> print ordered
[0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
>>> data.sort()
->>> print data == sorted
+>>> print data == ordered
True
>>>
\end{verbatim}