Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw

Re^4: Open to debate on mixins and traits.

by adrianh (Chancellor)
on Jun 03, 2004 at 14:37 UTC ( #360175=note: print w/replies, xml ) Need Help??

in reply to Re^3: Open to debate on mixins and traits.
in thread Open to debate on mixins and traits.

I don't see why Perl needs interfaces in any form, they're just there to satisfy the compiler in statically typed languages, aren't they?

No they're not ;-) Not if we're using the term as used in Java land anyway. They're a way of talking about common behaviour that cuts across class hierarchy boundaries.

In Perl 6 they're subsumed by roles (a Java interface would the equivalent to a role without any implementation code.)

(Note: Apply my standard "I've not read A12 properly yet" disclaimer to the previous sentence, but I'm sure chromatic will correct me if I'm wrong :-)

  • Comment on Re^4: Open to debate on mixins and traits.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://360175]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (1)
As of 2021-02-27 01:52 GMT
Find Nodes?
    Voting Booth?

    No recent polls found