From: Alex Martelli Date: Sun, 2 Nov 2003 19:39:14 +0000 (+0000) Subject: fix comments/docstring problems related to SF bug # 821818 X-Git-Tag: v2.3.3c1~83 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=c6ccfe1899e2348f2aced7c65ba92bb4dc126ecf;p=thirdparty%2FPython%2Fcpython.git fix comments/docstring problems related to SF bug # 821818 --- diff --git a/Lib/pyclbr.py b/Lib/pyclbr.py index 26cc0ce0dade..d536f5c0d5e6 100644 --- a/Lib/pyclbr.py +++ b/Lib/pyclbr.py @@ -7,13 +7,19 @@ The interface consists of a single function: readmodule_ex(module [, path]) where module is the name of a Python module, and path is an optional list of directories where the module is to be searched. If present, -path is prepended to the system search path sys.path. The return -value is a dictionary. The keys of the dictionary are the names of -the classes defined in the module (including classes that are defined -via the from XXX import YYY construct). The values are class -instances of the class Class defined here. One special key/value pair -is present for packages: the key '__path__' has a list as its value -which contains the package search path. +path is prepended to the system search path sys.path. The return value +is a dictionary. The keys of the dictionary are the names of the +classes and top-level functions defined in the module (including ones +that are defined via the from XXX import YYY construct). The values are +instances of the classes Class and Function defined here. One special +key/value pair is present for packages: the key '__path__' has as its +value a list which contains the package search path. + +(For compatibility, a function readmodule is also defined: it works just +like readmodule_ex, but the dictionary it returns has only key/value +pairs whose value is an instance of class Class, _not_ ones for which it +would be an instance of Function. nor the special key/value pair for key +'__path__' as described in the previous paragraph). A class is described by the class Class in this module. Instances of this class have the following instance variables: @@ -34,9 +40,9 @@ shouldn't happen often. A function is described by the class Function in this module. Instances of this class have the following instance variables: module -- the module name - name -- the name of the class - file -- the file in which the class was defined - lineno -- the line in the file on which the class statement occurred + name -- the name of the function + file -- the file in which the function was defined + lineno -- the line in the file on which the def statement occurred """ import sys