[PHP-DEV] Tip for 5.3: exceptions in __toString and __autoload

2008-12-25 Thread David Grudl
This code throws *Fatal error*: Method test::__toString() must not throw an exception class Test1 { public function __toString() { throw new Exception; } } The same problem causes throwing exceptions in function __autoload. I think this behavior is against the logic of

Re: [PHP-DEV] Tip for 5.3: exceptions in __toString and __autoload

2008-12-25 Thread Scott MacVicar
On 26 Dec 2008, at 01:46, David Grudl wrote: This code throws *Fatal error*: Method test::__toString() must not throw an exception class Test1 { public function __toString() { throw new Exception; } } The same problem causes throwing exceptions in function __autoload. I think

Re: [PHP-DEV] Tip for 5.3: exceptions in __toString and __autoload

2008-12-25 Thread Alexey Zakhlestin
On Fri, Dec 26, 2008 at 4:46 AM, David Grudl da...@grudl.com wrote: This code throws *Fatal error*: Method test::__toString() must not throw an exception class Test1 { public function __toString() { throw new Exception; } } The same problem causes throwing exceptions in