On Thursday 19 January 2006 06:48, Rob Kinyon wrote:

> "Any practical programming language with structural subtyping will
> probably let you create and use aliases for type names (so you don't
> have to write the full form everywhere). However, the underlying type
> system will only consider the structure of the type when doing its
> job."
>
> What's wrong with Perl doing things that way? duck-typing with names
> ... sounds like a plan to me ...

Accidental structural equivalence is a problem -- it's one of the things wrong 
with C's so-called type system, for example.

I like to think of roles as nominally-tagged (and checked) structural 
subtyping.  When you're *defining* a type, its structure matters.  When 
you're *using* it, its behavior matters.  It would be nice to keep those two 
separate.

-- c

Reply via email to