Rick DeNatale wrote: > Ruby, like Smalltalk, and Self, are languages which exemplify what > Ralph Johnson calls the "mystical view" of object-orientation, as > opposed the the "software engineering view" taken by C++/Java/Dylan.. > http://www.cincomsmalltalk.com/userblogs/ralph/blogView?showComments=true&printTitle=Erlang,_the_next_Java&entry=3364027251 > > Quoting Ralph: "The mystical view is that an OO system is one that is > built out of objects that communicate by sending messages to each > other, and computation is the messages flying from object to object. > The software engineering view is that an OO system is one that > supports data abstraction, polymorphism by late-binding of function > calls, and inheritance." > > A key difference between these two views is that in the mystical view, > the message name (i.e. the name used to represent a requested > operation) is defined independently of any type/class hierarchy. > Notice that Ralph's description of the mystical view makes no mention > of methods or functions. Although in most mystical languages most > messages result in the execution of a method with the name of the > message, this isn't always true, e.g. when a message is handled via > method_missing. > > The mystical view puts a wall of encapsulation between sender and > responder which isn't there in the software engineering view. The > sender names a request, and the receiver responds. The sender has no > knowledge of (and therefore no dependency on) just how the receiver > decides to implement the response. > > Adherents of the software engineering view tend to think, whether > consciously or unconsciously, in terms of late-bound function calls. > The model is that the caller knows how to find a particular 'virtual > function' and then invokes it. > > It's a subtle shift in viewpoint but it's crucial. Interesting distinction ... but some questions .... 1. Isn't there a continuum between the two "extremes"? 2. If so, where are Ruby, Scheme, Erlang and Forth on the continuum? 3. If either extreme is (or can be made) Turing-complete, why do nearly all languages include concepts catering to both?