Who's minister of propaganda this week?

Steven D. Majewski sdm7g at virginia.edu
Wed Mar 14 12:45:27 EST 2001


On Wed, 14 Mar 2001, Darren New wrote:

> Phlip wrote:
> > Ruby trumps Python in the simple matter of
> > closures (imagine my shock when I discovered Python didn't have them). 
> 
> Can someone summarize the important difference between closures and object
> instances? Other than convenience, I mean, it would seem that something like
> [ ... ] 

An object is a piece of data with procedures attached to it.
A closure is a procedure with a piece of data attached to it. 

Obviously, they are complete opposites! 

Well -- maybe "mirror images" is a better term.

If you read the HOPL articles on Lisp and Smalltalk, it's
clear that both groups were in communication with each other
and were aware of this -- they called it "orthigonality" --
both a different syntax, and a different way of looking at the 
same thing. 


-- Steve Majewski





More information about the Python-list mailing list