[Python-Dev] Those import related syntax errors again...

Jeremy Hylton jeremy@alum.mit.edu
Wed, 21 Feb 2001 11:45:30 -0500 (EST)


>>>>> "SP" == Samuele Pedroni <pedroni@inf.ethz.ch> writes:

  SP> My very personal feeling is that *any* rule on exec just sounds
  SP> arbitrary (even if motived and acceptable).

My personal feeling is that exec is used rarely enough that a few
restrictions on its use is not a problem.  The restriction can be
fairly minimal -- "exec" without "in" is not allowed in a function
that contains nested blocks with free variables.

Heck, we would just outlaw all uses of exec without in <0.5 wink>.
I would argue for this rule in Python 3000, but it would break a lot
more code than the restriction proposed above.

Jeremy