PEP 227 (was Re: Nested scopes resolution -- you can breathe again!)

Robin Becker robin at jessikat.fsnet.co.uk
Thu Mar 1 13:41:37 EST 2001


In article <mailman.983466367.2968.python-list at python.org>, Jeremy
Hylton <jeremy at alum.mit.edu> writes
>Or: global NAME in FUNCTION
>
>def eggs():
>    z = 2
>    def spam():
>        def inner():
>            global x in spam, z in eggs
>            x += 1
>            z += x
>        x = 23
>        inner()
>
>Jeremy
>
I like that a lot better than having it default possibly wrongly, but
how would this be doable/spelled in the lambda case?
-- 
Robin Becker



More information about the Python-list mailing list