Commit Graph

4 Commits

Author SHA1 Message Date
Jeremy Hylton
43454765c2 Export three optimization (fast locals) flags 2001-04-16 18:42:13 +00:00
Jeremy Hylton
8bf395f1aa add DEF_BOUND constant 2001-03-22 23:10:44 +00:00
Jeremy Hylton
cb17ae8b19 Relax the rules for using 'from ... import *' and exec in the presence
of nested functions.  Either is allowed in a function if it contains
no defs or lambdas or the defs and lambdas it contains have no free
variables.  If a function is itself nested and has free variables,
either is illegal.

Revise the symtable to use a PySymtableEntryObject, which holds all
the revelent information for a scope, rather than using a bunch of
st_cur_XXX pointers in the symtable struct.  The changes simplify the
internal management of the current symtable scope and of the stack.

Added new C source file: Python/symtable.c.  (Does the Windows build
process need to be updated?)

As part of these changes, the initial _symtable module interface
introduced in 2.1a2 is replaced.  A dictionary of
PySymtableEntryObjects are returned.
2001-02-09 22:22:18 +00:00
Jeremy Hylton
5e7cb240af Add minimal interface to symtable: _symtable module. 2001-02-02 18:24:26 +00:00