[Home] [Groups] - Message: [Prev in Group] [Next in Group]

nu.kanga.list.mud-dev

19836: Re: [MUD-Dev] Spoofs

[Full Header] [Plain Text]
From: "Bobby Martin" <bobbymartin@hotmail.com>
Newsgroups: nu.kanga.list.mud-dev
Date: Thu, 27 Sep 2001 18:00:04
Organization: Kanga.Nu
> From: Sean K <sean@hoth.ffwd.cx>

> C++ templates provide a similar feature to Smalltalk's typing but
> at compile time.  Between this and optional dynamic binding
> through virtual functions, C++ can accomplish everything that
> Smalltalk can, but it's not always as strightforward.

Hmm, I consider myself to be something of a C++ guru, and I don't
think that I buy this.  How do you make C++ emulate the
doesNotUnderstand behavior of a Smalltalk object?  In SmallTalk,
when you call a method on an object that doesn't implement that
method, it calls the doesNotUnderstand method on that object with
the actual method signature and parameters as arguments to the DNU
method.  I don't see how you could do an equivalent in C++ without
essentially writing a meta language.

Don't get me wrong; I love templates.  I think they do lots of
things that at least the vanilla SmallTalk implementations don't do
for you (like give you type safety).  I just don't think that it can
do everything SmallTalk can - it does different good things.

Bobby
_______________________________________________
MUD-Dev mailing list
MUD-Dev@kanga.nu
https://www.kanga.nu/lists/listinfo/mud-dev