Re: Traits and Properties
| From: | Stefan Marr | Date: | Thu, 06 Jan 2011 13:43:15 +0000 |
| Subject: | Re: Traits and Properties | ||
| References: | 1 2 3 4 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-51232@lists.php.net to get a copy of this message | ||
Hi Larry:
On 21 Dec 2010, at 03:24, Larry Garfield wrote:
> I don't believe the RFC mentions how those resolve in case of collision,
> though. If two traits define the same abstract method, does that cause a
> collision that needs manual resolution or can the using class just define it
> once and thereby support both traits?
Abstract methods do not cause collisions, no. So, there can be an arbitrary number of traits asking
for an abstract method with identical name, and the only thing that has to happen is that it is
implemented eventually, perhaps by another trait.
Best regards
Stefan
--
Stefan Marr
Software Languages Lab
Vrije Universiteit Brussel
Pleinlaan 2 / B-1050 Brussels / Belgium
http://soft.vub.ac.be/~smarr
Phone: +32 2 629 2974
Fax: +32 2 629 3525