Ferdinand Beyer wrote:

On 1 Jun 2004 at 21:13, Timm Friebe wrote:


Yes: self is bound at compiletime. It would need to be changed to
evaluation at runtime und would be far more useful then.

[...]

I wouldn't mind chaning self in the first place, though.


I prefer your solution to evaluate self at runtime instead of adding a new keyword 'this'. The second one would only be confused with $this. Many people (including me) are already familiar with 'self' and expect it to refer to the class from within it is called.


Yeah +1 on self:: binding at runtime. I can't really imagine a case where you would want to refer to 'self' as the class that contains the method *and not* the overridden method in invoked class (if it exists). Binding this at runtime will introduce many new design possibilities with static classes and will also make self:: consistent with $this-> behavior for objects.


Hans

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to