Re: 5.4a2 trait attribute name conflict resolution

From: Date: Sat, 23 Jul 2011 18:18:23 +0000
Subject: Re: 5.4a2 trait attribute name conflict resolution
References: 1 2 3 4 5 6  Groups: php.internals 
Request: Send a blank email to [email protected] to get a copy of this message
Hi Mike:

On Sat, Jul 23, 2011 at 6:49 PM, Mike Stowe <[email protected]> wrote:
> So am I understanding correctly that the initial properties must be identical both in type and
> value, otherwise it would throw an error. To me that would make the most sense as they could be
> overridden in a construct or other method.

Yes, they have to be perfectly identical. Any difference indicates, in
this strict model, a potential conflict and different semantics of
that particular property i.e. the state.
Since we do not provide any means to manage such conflicts, we bail
out as early as possible and ask the programmer to fix his code by
ensuring everything is compatible.

Best regards
Stefan


Thread (18 messages)

« previous php.internals (#54160) next »