summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEzio Melotti <ezio.melotti@gmail.com>2013-04-18 23:53:12 (GMT)
committerEzio Melotti <ezio.melotti@gmail.com>2013-04-18 23:53:12 (GMT)
commit72b8502992d3ee282e46231a953852c6a78fb000 (patch)
tree92fb56fc176e51ee50cc706c3d3ac27738ff2151
parentf476405503c0ea80541df26cda7a4fa6af263659 (diff)
downloadcpython-72b8502992d3ee282e46231a953852c6a78fb000.zip
cpython-72b8502992d3ee282e46231a953852c6a78fb000.tar.gz
cpython-72b8502992d3ee282e46231a953852c6a78fb000.tar.bz2
#11182: remove the unused and undocumented pydoc.Scanner class. Patch by Martin Morrison.
-rwxr-xr-xLib/pydoc.py24
-rw-r--r--Misc/ACKS1
-rw-r--r--Misc/NEWS3
3 files changed, 4 insertions, 24 deletions
diff --git a/Lib/pydoc.py b/Lib/pydoc.py
index 4d681b0..7505ccd 100755
--- a/Lib/pydoc.py
+++ b/Lib/pydoc.py
@@ -1984,30 +1984,6 @@ for modules whose name or summary contain the string "spam".
help = Helper()
-class Scanner:
- """A generic tree iterator."""
- def __init__(self, roots, children, descendp):
- self.roots = roots[:]
- self.state = []
- self.children = children
- self.descendp = descendp
-
- def next(self):
- if not self.state:
- if not self.roots:
- return None
- root = self.roots.pop(0)
- self.state = [(root, self.children(root))]
- node, children = self.state[-1]
- if not children:
- self.state.pop()
- return self.next()
- child = children.pop(0)
- if self.descendp(child):
- self.state.append((child, self.children(child)))
- return child
-
-
class ModuleScanner:
"""An interruptible scanner that searches module synopses."""
diff --git a/Misc/ACKS b/Misc/ACKS
index 734a17c..36b98b0 100644
--- a/Misc/ACKS
+++ b/Misc/ACKS
@@ -848,6 +848,7 @@ Ross Moore
Ben Morgan
Derek Morr
James A Morrison
+Martin Morrison
Derek McTavish Mounce
Alessandro Moura
Pablo Mouzo
diff --git a/Misc/NEWS b/Misc/NEWS
index 098d328..bccc52b 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -45,6 +45,9 @@ Core and Builtins
Library
-------
+- Issue #11182: remove the unused and undocumented pydoc.Scanner class.
+ Patch by Martin Morrison.
+
- Issue #17741: Add ElementTree.IncrementalParser, an event-driven parser
for non-blocking applications.