summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFred Drake <fdrake@acm.org>2001-08-13 20:20:51 (GMT)
committerFred Drake <fdrake@acm.org>2001-08-13 20:20:51 (GMT)
commit03f7a70345fe7bb59ee15f1f76ce9c9ca36e3d59 (patch)
treee2e227b384bd617d032c86cf990939265c141a80
parent6943a29cbf2cc5a743cb55857b623f7ab3168190 (diff)
downloadcpython-03f7a70345fe7bb59ee15f1f76ce9c9ca36e3d59.zip
cpython-03f7a70345fe7bb59ee15f1f76ce9c9ca36e3d59.tar.gz
cpython-03f7a70345fe7bb59ee15f1f76ce9c9ca36e3d59.tar.bz2
Nick Mathewson: Make sure the recursion is handled properly.
This is part of SF patch #440292.
-rw-r--r--Lib/pyclbr.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/Lib/pyclbr.py b/Lib/pyclbr.py
index 4a153ca..95479a7 100644
--- a/Lib/pyclbr.py
+++ b/Lib/pyclbr.py
@@ -166,8 +166,8 @@ def readmodule_ex(module, path=[], inpackage=0):
# Dotted module name
package = module[:i].strip()
submodule = module[i+1:].strip()
- parent = readmodule(package, path, inpackage)
- child = readmodule(submodule, parent['__path__'], 1)
+ parent = readmodule_ex(package, path, inpackage)
+ child = readmodule_ex(submodule, parent['__path__'], 1)
return child
if _modules.has_key(module):
@@ -295,7 +295,7 @@ def readmodule_ex(module, path=[], inpackage=0):
n = n.strip()
try:
# recursively read the imported module
- d = readmodule(n, path, inpackage)
+ d = readmodule_ex(n, path, inpackage)
except:
##print 'module', n, 'not found'
pass
@@ -306,7 +306,7 @@ def readmodule_ex(module, path=[], inpackage=0):
names = m.group("ImportFromList").split(',')
try:
# recursively read the imported module
- d = readmodule(mod, path, inpackage)
+ d = readmodule_ex(mod, path, inpackage)
except:
##print 'module', mod, 'not found'
continue