nested functions
Tim Peters
tim_one at email.msn.com
Sat Feb 26 01:29:59 EST 2000
[Tim, sketches what happens at runtime when building a function object]
[François Pinard]
> It looks more powerful than I imagined! Isn't this one more step towards
> lexical closures? :-)
Well, Python *already* has closures. They're just more like the Java inner
class flavor than the Scheme flavor: explicit importation of objects across
scope boundaries, instead of implicit importation of names across scope
boundaries. Python's flavor is actually *nice* "in the large" because it
makes the boundary leaks explicit. Ir's "in the small" that it sucks by
comparison.
> Thanks for educating me, and sharing this fine information with us.
An answer can only aspire to being but a pale reflection of the glory of the
question, so thank *you* for the opportunity to fall short once again
<wink>.
the-joy-is-in-striving-ly y'rs - tim
More information about the Python-list
mailing list