Re: RFC: Traits for PHP

From: Date: Tue, 19 Feb 2008 21:46:57 +0000
Subject: Re: RFC: Traits for PHP
References: 1 2 3 4 5  Groups: php.internals 
Request: Send a blank email to internals+get-35618@lists.php.net to get a copy of this message
Hi Stanislav, > > traits the included trait is using). Ok this is the scope. Now we > > would need to adjust all those method bodies, find all method calls on > > $this->oldMethodName() and change them to $this->newMethodName(). > > You can't - PHP has dynamic method resolution (think $this->$foo()). > Also, it has callbacks - what happens if method is registered as > callback is renamed? thanks, this is very good reason not to allow renaming, but aliasing. :) Kind Regards Stefan

« previous php.internals (#35618) next »