Re: horizontal reuse: traits vs. grafts
| From: | troels knak-nielsen | Date: | Thu, 25 Mar 2010 17:14:03 +0000 |
| Subject: | Re: horizontal reuse: traits vs. grafts | ||
| References: | 1 2 3 4 5 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-47614@lists.php.net to get a copy of this message | ||
Hi
On Thu, Mar 25, 2010 at 4:00 PM, Lukas Kahwe Smith <mls@pooteeweet.org> wrote:
> On 25.03.2010, at 14:48, David Soria Parra wrote:
>> Stefan what do you think about "stackable traits" ?
>
>
> Woha .. that code really scares me.
>
While I like features like this in other languages, I think it would
be a big break with PHP's model. PHP has always had a rather static
object model, which may be somewhat limiting, but has the benefit of
being easy to comprehend. Traits/Grafts stays within this paradigm,
but making it possible to modify objects dynamically would be
stretching it.
--
troels