On Wed, 05 Mar 2003 13:31, Brent Dax wrote:# *) A superclass (obviously, but I consider it to be the # same level as # Properties, Methods and Attributes.) Superclass*es*. Perl 5 has MI, and I don't expect that to change in Perl 6. Parrot absolutely *must* support Perl, or it has failed in its primary goal. # *) a set of Interfaces (similar to multiple inheritance; a way of # grouping methods associated with a class for another to # implement). # eg, in Java and IDL. Can this be implemented in terms of MI and/or delegation? (For Perl 6's part, my understanding is that an interface is just a class that inherits from Interface--although I could *easily* be wrong about that.)
Whether to implement interfaces using Multiple Inheritance, or Multiple Inheritance using Interfaces is a half empty/half full decision. It makes little difference.
What I'm saying is that it should be possible to `filter' which methods you inherit via @ISA.
That's up to the language using Parrot. Given that parent classes should be reasonably opaque, I'm not sure it's a Good OO Thing. OTOH, I think most of the anal OO stuff is a load of rubbish, so who am I to say no? :)
Seriously, for this the class can either take control of method lookup explicitly and redispatch as it sees fit, or install a dummy "you lose" method for the blocked methods. I'd probably go with the latter.
[Lots of association stuff snipped]
Ah, I see. Not parrot's problem. (And, FWIW, bringing real-world analogies into OO discussions is, in my experience, confusing, since OO style relationships don't mirror real-world ones. But that may just be me)
--
Dan
--------------------------------------"it's like this"------------------- Dan Sugalski even samurai [EMAIL PROTECTED] have teddy bears and even teddy bears get drunk