|
|
| Keep It Simple, Stupid | |
| PerlMonks |
Comment on |
| ( #3333=superdoc: print w/ replies, xml ) | Need Help?? |
|
The problem this solves is very real-world. Consider a Perl class hierarchy in which a class Child inherits from classes Mother and Father:
Uh, oh. Multiple Inheritance. A couple of years of doing Smalltalk (which didn't have multiple inheritance, but which let you fake interface interitance via mixins), and a couple of years of Java and C++ have lead me to believe that Multiple Inheritance is a Very Risky Thing, and that it can always be worked around by either composition or reducing to inheriting from one data-bearing class and multiple (data-less) interface classes. Doing so avoids the multiple destructor problem. Perhaps you've run into a situation where multiple inheritance is the right thing to do. If so, I'd like to hear about it.
In reply to Re: Re: •Re: RFC: Class::DispatchToAll
by dws
|
|