Our original idea was to handle this with an if statement like so:
if (version_compare(phpversion(), "5.0.0") == -1) {
// assign factoried method to this for PHP 4
// $this =& <Your_Package_Name>::factory();
$this =& <Your_Package_Name>::singleton();
} else {
// error handling for PHP5
// user has to use the factory()/singleton() method
}
I guess to make it clear, what I want is that PHP5 only explodes if it is actually asked to execute an assignement to $this and not just because there is one in the constructor. However Derick just messed around with the relevant code and didnt immediatly see a solution.
regards, Lukas Smith
-- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php
