[Python-ideas] Tweaking closures and lexical scoping to include the function being defined
Guido van Rossum
guido at python.org
Thu Sep 29 22:01:12 CEST 2011
On Thu, Sep 29, 2011 at 12:03 PM, Eric Snow <ericsnowcurrently at gmail.com> wrote:
> The alternative is to leave nonlocal as just a simple statement, but
> change its behavior when the name is not found inside a containing
> function scope. Currently that is a syntax error.
For a reason. It would be too easy for a typo to produce the wrong
interpretation.
--
--Guido van Rossum (python.org/~guido)
More information about the Python-ideas
mailing list