Traits, r?les and other repurposed terms

Ovid publiustemp-londonpm at yahoo.com
Fri Feb 8 14:15:07 GMT 2008


--- Adrian Howard <adrianh at quietstars.com> wrote:

> > --- Abigail <abigail at abigail.be> wrote:
> >
> >> (Of course, "roles" is just "multiple inheritance" with a
> different
> >> name.
> >
> > With all due respect, this is not even remotely true.
> [snip]
> 
> I think that depends on how you define MI and roles :-)
> 
> For example Eiffel's OO model (ignoring the switching roles/traits
> in/ 
> out at runtime - which it doesn't handle)

Oops.  OK, so for C++, Java, C#, Ruby, Python, Perl, etc., they're not
the same thing :)

I really do like the idea Eiffel has of being explicit about the
redefinition/renaming of inherited methods, but as noted, you don't get
the runtime benefits (very similar to prototype-based classes) or the
introspective separation of 'does-a' versus 'is-a', though in the case
of Eiffel, I'm not sure how that would play out.  Since I'm comfortable
with traits but not with Eiffel, I can't say much more than that.

Though for smaller-scale systems, this can be arguing about how many
angels can dance on the head of a pin :)

Cheers,
Ovid

--
Buy the book  - http://www.oreilly.com/catalog/perlhks/
Perl and CGI  - http://users.easystreet.com/ovid/cgi_course/
Personal blog - http://publius-ovidius.livejournal.com/
Tech blog     - http://use.perl.org/~Ovid/journal/


More information about the london.pm mailing list