Friday, November 19, 2010

Alan Kay on Object-Oriented Programming

Some interesting statements of Alan Kay (one of the Smalltalk creators) about object-oriented programming:
"My original thought was to have something like recursive biological cells. We have about 10 to the 14th power of cells in our body. That is a hell of a lot more cells than there are nodes on the Internet. Those cells spend almost all of their effort keeping themselves normal. They're self-repairing, and you don't have to stop the organism in order to affect repairs. And then there are some interesting mathematical properties of this kind of thing that also occurred to me, and I called those things objects." [1]
"So I thought of objects being like biological cells, only able to communicate with messages (so messaging came at the very beginning - it took a while to see how to do messaging in a programming language efficiently enough to be useful)." [2]
"Object-oriented programming to me means only messaging, encapsulating and hiding state, and extreme late-binding of all things. It could be done in Smalltalk and in LISP. There are possibly other systems in which this is possible, but I'm not aware of them." [3]
"The big idea is "messaging" - that is what the kernel of Smalltalk/Squeak is all about (and it's something that was never quite completed in our Xerox PARC phase). The key in making great and growable systems is much more to design how its modules communicate rather than what their internal properties and behaviors should be." [4]
"Until real software engineering is developed, the next best practice is to develop with a dynamic system that has extreme late binding in all aspects." [5]

I think, Erlang and the QNX Neutrino RTOS definitely belong to those kind of systems. The fact that the above statement also defines QNX Neutrino RTOS as an object-oriented platform shows that particular technologies often do not matter as much as the right architectures and paradigms.
Also Apple's Objective-C platform and Google's Android OS are heavily based on message passing. That's why all this stuff works so great :-)

PS: some thoughts on message passing from the Erlang, Scala and F# creators.