News for hackers. Stuff that matters.
Re:What is meant by “protection” in real OOP? by xkriva11 on Thursday April 23, 2020 @03:18PM (#22959963)
In Smalltalk, the only way how to communicate to objects is by sending messages. The way how they react on the messages is full the responsibility of objects, and they can refuse them. This decision is strictly late-bound because all message passing in Smalltalk is late-bound. You may say that all the methods in Smalltalk are "public", but it is not the very same meaning as in other languages.

The objects store the state in instance variables. You cannot access the instance variables of objects from outside of the object. All instance variables are "protected" in the terminology of C++.

Re:What is meant by “protection” in real OOP? by tresilience on Friday April 24, 2020 @05:03AM (#22966049)
> The way how they react on the messages is full the responsibility of objects, and they can refuse them.

Thereby any further protection is totally up to the programmer right?

Re:What is meant by “protection” in real OOP? by xkriva11 on Friday April 24, 2020 @08:22AM (#22967180)
Yes. It is actually very easy to extend Smalltalk to support private/protected methods (message bytecode based on the protocols, for example). But Smalltalk would need to do these checks in run-time because all message sends are late-bound.
Re:What is meant by “protection” in real OOP? by tresilience on Friday April 24, 2020 @12:45PM (#22970099)
Thanks! Can you point me to where I can find out more about the eval-"loop" that the entire Smalltalk runs on?
Re:What is meant by “protection” in real OOP? by xkriva11 on Thursday April 30, 2020 @04:24PM (#23035654)