i do not know the real reason or history. so i am curious to learn, too.
my impression is that method calls were sort of a typical
misunderstanding / overzealous premature optimization implementation
of messaging. (method calls tend to be more tightly bound than the
dynamic nature of messaging.)
sincerely.
Trygve Reenskaug mailto: try...@ifi.uio.no
Morgedalsvn. 5A http://heim.ifi.uio.no/~trygver
N-0378 Oslo Tel: (+47) 22 49 57 27
Norway
http://www.infoq.com/interviews/ingalls-smalltalk
As far as I remember it, performance was really the main reason
why they introduced methods. At least in Smalltalk.
Sebastian K�beck
It confirmed some of my expectations. Objective C is just Smalltalk that
couldn't let go of the C legacy. I can see the (old) reasoning behind this
decision. Sure now we have to deal with its syntax but hey... they took what
was available and made of it, something more.
Smalltalk seems to be VERY versatile, it's dynamic+objective nature means I
can replace an object and write it in another language altogether, just plug
it in and go.
What I can't get, is why would the "newer" languages like C# opt out of
messaging. Why would anyone want, like Raoul said, WANT a more "tightly
bound" less dynamic, ecosystem.
Less dynamic means you can navigate adjacent objects easier
(intellisense?!), and via this, people learn/use the your library faster.
But being tightly bound at the same time would make everything like
"glue"... hard to escape. Once you en"code" your project with the "help" of
a certain library, you're stuck. Misunderstood(bad) OO can "help" this even
more, there is no clear boundary, you'd have to replace whole parts of your
implementation at a time, with no "hot-wire" capability.
It seems I'm describing the perfect business model for someone dealing in
software "coin". This needs more peering into...
-----Original Message-----
From: object-co...@googlegroups.com
[mailto:object-co...@googlegroups.com] On Behalf Of Sebastian Kübeck
Sent: 20 octombrie 2010 10:13
To: object-co...@googlegroups.com
Subject: Re: "Smalltalk style messaging" vs "Method call"
Maybe it helps if you watch Dan Ingalls on the History of Smalltalk and the
Lively Kernel:
http://www.infoq.com/interviews/ingalls-smalltalk
As far as I remember it, performance was really the main reason why they
introduced methods. At least in Smalltalk.
Sebastian Kübeck
--
You received this message because you are subscribed to the Google Groups
"object-composition" group.
To post to this group, send email to object-co...@googlegroups.com.
To unsubscribe from this group, send email to
object-composit...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/object-composition?hl=en.
sincerely.
On Wed, Oct 20, 2010 at 1:37 PM, Raoul Duke <rao...@gmail.com> wrote:
> i can think of several reasons off the top of my head :-)
i can think of several reasons off the top of my head :-)
* compile-time understanding of the system?
* ability to give code to other people and not have to find out that
they've changed their running image over time so like, oh i dunno,
Boolean (mostly kidding, but you never know) is not compatible?
* performance?
* generally wanting to interact with other languages/systems?
sincerely.
ah, that must be why you are one of the apparently more insightful
folks. (seriously.)
A method is an operation on an object. It has a name, called a method selector, and it can have arguments (formal parameters). In Smalltalk, methods are also objects.
A message is a combination of an object identifier, method selector, and actual parameters, bundled together for dispatching to an object. The environment causes the message to be "routed" to the right place based on the object identifier (which in turn can be used to find a method lookup table) and the method selector.
The nomenclature in C++ is different. C++ has neither methods nor method selectors, but has member functions.
I don't know the nomenclature, in detail, for other languages.
queareArea(x) or circleArea(x) where x
is the size of the square or the radius of the circle.x.areaSquare will have a method called area
(=squareArea), class Circle will have its own and
different method called area (=circleArea). The two
methods are different, but they can be called the same since they are
defined in different classes.area, it is asking the receiver 'to do the
right thing'.Thank you for the explanation.
It’s really interesting how the concepts behind Smalltalk seem to have a certain logic to them, or should I say that the assumptions seem to be correct.
I’ve been reading further back “in time”, to Dijkstra and SUPRISINGLY to Christopher Alexander who incidentally is an architect.
His Notes on the Synthesis of Form, and A Pattern Language read into Smalltalk very well. He seems to have influenced things a lot.
Guess I’ve gone full circle.
Mircea.
From: object-co...@googlegroups.com [mailto:object-co...@googlegroups.com] On Behalf Of Trygve Reenskaug
Sent: 21 octombrie 2010 12:24
To: object-co...@googlegroups.com
Subject: Re: "Smalltalk style messaging" vs "Method call"
In procedure-oriented programming you must say
--