Live data from Hacker News

Alan Kay on the Meaning of “Object-Oriented Programming” (2003)

purl.org

11–20 of 58 posts

Re: Alan Kay on the Meaning of “Object-Oriented Programming” (2003)

#11
I wonder what he thinks of Erlang, as it's very much about message passing, hiding of process state, and late binding. Of course, this is built at a higher level and it's not turtles all the way down: you don't send messages to numbers to do basic math.

Re: Alan Kay on the Meaning of “Object-Oriented Programming” (2003)

#12

A lot of the recent trend towards OOP-bashing comes from bad implementations of OOP, just as bashing design patterns is more to do with badly thought out architectures and overuse of those patterns. In fact, the origins of OOP are basically what we would now call microservice architecture (CSP-inspired languages like Go being a specialisation of this). Each service can be as stateless or as stateful as it needs to be…

In sports, training coaches sometimes forbid to use some play element. In OOP classes there should be an assignment to design a system without inheritance. Just to show what is most important in OOP.

Re: Alan Kay on the Meaning of “Object-Oriented Programming” (2003)

#14
post #3

Towards the end: But just to show how stubbornly an idea can hang on, all through the seventies and eighties, there were many people who tried to get by with "Remote Procedure Call" instead of thinking about objects and messages. Sic transit gloria mundi. Can somebody explain to me what distinction he's drawing here? What's the issue with RPC that's solved by Objects+Messages?

I wish you hadn't asked this question b/c it sent me on a wild goose chase, mainly as I tried to reconcile my understanding of OOP vs. Kay's version of it, of which I'm still unclear. I perused the [1] he mentions to try and get better insight. (My version is much more born out of my history w/ C++/Java.)

Kay says,

    OOP to me means only messaging, local retention and protection and hiding of state-process, and extreme late-binding of all things.
I read this to simply mean encapsulation of state + dynamic typing. RPC as I understand it is making a method call from one process to another, which makes no claim on how state and/or data should be handled and modeled.

So I'm with you. Is Kay just arguing here for a specific way of thinking and talking about computing? Or are there some more concrete/tangible computing rules implied by what he's saying?

[1] Dataless Programming (http://www.rand.org/content/dam/rand/pubs/research_memoranda...)

Re: Alan Kay on the Meaning of “Object-Oriented Programming” (2003)

#15

"OOP to me means only messaging, local retention and protection and hiding of state-process, and extreme late-binding of all things." Bam. That is it right there. Java really messed this up. Strong static typing and OO is an abomination.

So what specifically about OO gets so much better as soon as you take types away? Can you give a specific improvement?

Re: Alan Kay on the Meaning of “Object-Oriented Programming” (2003)

#16
post #9

A lot of the recent trend towards OOP-bashing comes from bad implementations of OOP, just as bashing design patterns is more to do with badly thought out architectures and overuse of those patterns. In fact, the origins of OOP are basically what we would now call microservice architecture (CSP-inspired languages like Go being a specialisation of this). Each service can be as stateless or as stateful as it needs to be…

It seems to me that you can't really do message passing in most languages with high efficiency? (Objective-C and Swift being the exceptions.)

I think it's a bit charitable to call what Objective C does to be "message passing". The messages are not asynchronous and have only a single recipient, so in practice I would say they're method calls with late binding.

Re: Alan Kay on the Meaning of “Object-Oriented Programming” (2003)

#17
post #8
post #3

Towards the end: But just to show how stubbornly an idea can hang on, all through the seventies and eighties, there were many people who tried to get by with "Remote Procedure Call" instead of thinking about objects and messages. Sic transit gloria mundi. Can somebody explain to me what distinction he's drawing here? What's the issue with RPC that's solved by Objects+Messages?

A remote procedure call blocks on the response, ensuring the system is only as strong as its weakest link. If every object communicates asynchronously with every other object, using messages instead of shared memory (hence avoiding locking issues), the design by necessity evolves in ways which becomes more robust and easy to scale. Synchronous RPC calls encourage unscalable and unreliable architectures.

All remote calls must have a timeout. The lack of timeouts in certain RPC implementations was an implementation weakness, not a conceptual one.

[Edit: I've removed most of my original comment since it pertained to messaging between machines, rather than within an application.]

Re: Alan Kay on the Meaning of “Object-Oriented Programming” (2003)

#18

A lot of the recent trend towards OOP-bashing comes from bad implementations of OOP, just as bashing design patterns is more to do with badly thought out architectures and overuse of those patterns. In fact, the origins of OOP are basically what we would now call microservice architecture (CSP-inspired languages like Go being a specialisation of this). Each service can be as stateless or as stateful as it needs to be…

If we redefine the word "OOP:object" to mean process-with-mailbox, and redefine the word "OOP:message" to mean asynchronous message passing, then objects and messages make sense and are useful.

Those are not Smalltalk's definitions -- even though I think you're right on about Alan Kay's original inspiration -- and confusion can arise if we redefine terms.

Re: Alan Kay on the Meaning of “Object-Oriented Programming” (2003)

#19
post #13

>My math background made me realize that each object could have several algebras associated with it, and there could be families of these algebras Could someone explain what he meant here?

For example an automobile can be thought of as an emitter of pollution, if your problem concerns pollution, or, it can be thought of as a particle, if your problem concerns traffic congestion.

The auto "fits" into each of these different problem domains.

Re: Alan Kay on the Meaning of “Object-Oriented Programming” (2003)

#20
post #13

>My math background made me realize that each object could have several algebras associated with it, and there could be families of these algebras Could someone explain what he meant here?

For example an automobile can be thought of as an emitter of pollution, if your problem concerns pollution, or, it can be thought of as a particle, if your problem concerns traffic congestion. The auto "fits" into each of these different problem domains.

Thanks for the reply, but I'm still not seeing the connection to algebra?
Post reply on HN