diff options
| author | Neal Norwitz <nnorwitz@gmail.com> | 2005-11-25 03:14:00 (GMT) | 
|---|---|---|
| committer | Neal Norwitz <nnorwitz@gmail.com> | 2005-11-25 03:14:00 (GMT) | 
| commit | 21d19f7203f147622dfab9ddcc3efe1e0d71cd70 (patch) | |
| tree | 619b322f756451a71bbb7712206c42a8902009c3 /Lib/symtable.py | |
| parent | 545d4962f5860c49c44f06fc80c4678271cfac18 (diff) | |
| download | cpython-21d19f7203f147622dfab9ddcc3efe1e0d71cd70.zip cpython-21d19f7203f147622dfab9ddcc3efe1e0d71cd70.tar.gz cpython-21d19f7203f147622dfab9ddcc3efe1e0d71cd70.tar.bz2  | |
Get symtable to limp along, can run compiler/symbols.py.  Not saying much, needs more work.
Diffstat (limited to 'Lib/symtable.py')
| -rw-r--r-- | Lib/symtable.py | 5 | 
1 files changed, 4 insertions, 1 deletions
diff --git a/Lib/symtable.py b/Lib/symtable.py index 38042ae..3f1332e 100644 --- a/Lib/symtable.py +++ b/Lib/symtable.py @@ -13,7 +13,10 @@ __all__ = ["symtable", "SymbolTable", "newSymbolTable", "Class",  def symtable(code, filename, compile_type):      raw = _symtable.symtable(code, filename, compile_type) -    return newSymbolTable(raw[0], filename) +    for top in raw.itervalues(): +        if top.name == 'top': +            break +    return newSymbolTable(top, filename)  class SymbolTableFactory:      def __init__(self):  | 
