On Fri, Mar 2, 2012 at 12:06 PM, Federico Ulfo <rainelemen...@gmail.com> wrote:
> I've to correct what I wrote before about traits.
>
> PHP 5.4 implements traits instead of multiple inheritance, because the
> multiple inheritance can cause the "diamond problem"
> http://en.wikipedia.org/wiki/Diamond_problem

That article explains in detail how the problem is handled in other
languages. And traits can still result in conflicts that look pretty
darned similar to the diamond problem, which result in a fatal error.

So I think your question is still a good one. Nevertheless, I'm glad
we've got another way to reduce the amount of boilerplate in our
classes.
_______________________________________________
New York PHP User Group Community Talk Mailing List
http://lists.nyphp.org/mailman/listinfo/talk

http://www.nyphp.org/show-participation

Reply via email to