|
|
|
|
|
by lisper
1513 days ago
|
|
> I just want to send a message to an object Why? Seriously, why is that something you want? Why do you want sending a message to be syntactically and semantically distinct from calling a function? > The problem people get into with OO (particularly Java, C#, C++) is thinking in terms of method-function calls rather than message sends. Well, IMHO the problem people get into with OO is thinking that there is something special about sending a message that is different from calling a function. Sending a message is an implementation technique, not a semantically distinct action that should be exposed in the language semantics, and certainly not in the syntax. |
|
In Java it is pretty much just a function call, because the code in the callee has the ability to wreak all kinds of havoc in real Java programs, so the pattern of "messages" is quite imperfectly related to the authorities you're bounding.
More at http://habitatchronicles.com/2017/05/what-are-capabilities/