Version 23 of Selfish

Updated 2011-08-24 07:09:21 by arjen

See http://people.fishpool.fi/~setok/proj/Selfish/ for preliminary implementation.

MJ -- Really nice work, after playing with it a bit, it really shows the power and ease of prototype based OO. However a [super] call is missing; this will make inheritance less useful than it can be. See also self.


MJ -- Is this a bug in slot lookup?

 % set a [selfish::baseObject clone]
 ::selfish::0
 % ::selfish::slot ::selfish::baseObject test {} {puts test}
 foo
 % $a test
 SelfishError exception thrown: Could not find slot test

MJ -- To answer my own question, this is not a bug, but a different way of cloning from Self. In an Prototype based OO language there are two distinct ways of cloning a prototype [L1 ]. One way is cloning with delegation (like Self) the other way is concatinative prototyping (What Selfish, neo, eos seem to be using). With concatenative cloning, there is no relation after cloning between the prototype and the cloned object.

RLH -- Wasn't there more here before? MS: yes - MJ's code, I think. Now at SELF. MJ: I moved it indeed as it felt like I was hijacking this page, and the code fit better on the Self page.

tb It seems to me that the page SELF was hijacked by TclOO. I remember a different content. Is it lost?

AM No, the code is still there, but the page starts with the TclOO command [self], look further down for the original discussion on the language and the emulation by MJ.


[ Category Object Orientation | Category Package ]