From: Fred Drake Date: Mon, 6 Oct 1997 21:06:29 +0000 (+0000) Subject: Reduced number of temporary names used at module scope. Use underscores in X-Git-Tag: v1.5a4~69 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=dc1a072e02096480520020f0fa37f4d5995a8b43;p=thirdparty%2FPython%2Fcpython.git Reduced number of temporary names used at module scope. Use underscores in front of temporary names in the module namespace. --- diff --git a/Lib/symbol.py b/Lib/symbol.py index 4a71968b252d..678e9efae204 100755 --- a/Lib/symbol.py +++ b/Lib/symbol.py @@ -72,12 +72,10 @@ arglist = 311 argument = 312 #--end constants-- -names = dir() sym_name = {} -for name in names: - number = eval(name) - if type(number) is type(0): - sym_name[number] = name +for _name, _value in globals().items(): + if type(_value) is type(0): + sym_name[_value] = _name def main():