Ron Adam wrote:
> How about limiting nonlocal to just the immediate parent scope and using
> 'parent' as the keyword?
That could lead to confusing situations. What should
the following do:
def f():
x = 42
def g():
def h():
parent x
x = 88
Should the assignment to x in h() create a name in
the scope of g() even though there's no assignment
in g() to establish that as its home scope? Should
it be an error?
--
Greg
_______________________________________________
Python-3000 mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-3000
Unsubscribe:
http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com