RE: RFC 265 (v3) Interface polymorphism considered lovely
[email protected] (David Grove) Fri, 29 Sep 2000 20:12:38 -0500
| Newsgroups | perl.perl6.language.objects |
|---|---|
| Organization | Pete's Place |
| Message-ID | <[email protected]> |
> Java is one language that springs to mind that uses interface > polymorphism. Don't let this put you off -- if we must steal something > from Java let's steal something good. Interface inheritance is probably the least dignified thing to steal from Java. If we have true multiple inheritance, interfaces don't apply. (As a C++ programmer, I've always had to consider the interface OOP of Java and Delphi as flawed and incomplete. By golly, a dog CAN be a furred animal AND a four legger without having to define one or the other entirely in each class where I want either a furred animal and a four legger.) We already have true multiple inheritance. Therefore, interface OOP is unnecessary. However, some syntactic sugar to accomplish what you are looking for might be in order. Maybe implements() or isa()? (Is a())