On Mon, 16 Aug 2004 20:54:34 -0700
chromatic <[EMAIL PROTECTED]> wrote:

> On Mon, 2004-08-16 at 11:30, Michel Pelletier wrote:
> 
> > I've noticed there are ops for interfaces, but no implementation or
> > ppd yet.
> 
> Perl 6 has roles which are much more useful than interfaces -- in
> fact, interfaces are degenerate roles.  See Apocalypse 12 for more.
> 
>       http://www.perl.com/pub/a/2004/04/16/a12.html

Mmm.  Some light reading.  Now at least I know where BUILD comes from. I
think I get it, but correct me if I'm wrong: Roles are an orthogonal
structure to classes, like classes but they describe not an inheritance
relationship, but a functional relationship between an object an the
behavior other object expect from it, irregardless of its pedigree, and
to a degree, its implementation langauge.

> Parrot does/should have the 'does' op, which ought to check and
> identify roleishness.  I don't know its current status.

To my novice eyes, unimplemented.  But what implements a Role?  A
modified class?
 
> Discussion as to the differences between roles and interfaces should
> probably happen on p6l ([EMAIL PROTECTED]), though there are
> some implementation details for Perl 6's signature checking system
> that Parrot doesn't currently handle as it could.

>From a cross language standpoint I'm wondering less about Perl 6 roles
specificly or how they are implemented, and more about how roles are
going to work between components and languages, particularly from the
perspective of adaptation, ala PEP 246 or PyProtocols:

http://www.python.org/peps/pep-0246.html (Object Adaptation)

http://peak.telecommunity.com/PyProtocols.html

Both interesting reads from a cross-language standpoint, especially the
latter:

"PyProtocols also doesn't force you to use a particular interface coding
style or even a specific interface type. You can use its built-in
interface types, or define your own. If there's another Python package
out there with interface types that you'd like to use (CORBA?  COM?),
you can even create your own adapters to make them work with the
PyProtocols API. "

not just "another Python Package out there with interfaces" but now
Parrot lets use use another *language* with interfaces.  Will roles
(interfaces) with adaptation improves the ability for components written
in different langauges to cross language barriers?

-Michel

Reply via email to