[TYPO3-dev] Change die to throw new Exception for 4.2?

Ingo Renner ingo at typo3.org
Mon Sep 17 16:56:15 CEST 2007


ries van Twisk wrote:
> Hey Core devs,
> 
> would it be a good idea to
> change all die functions in core to
> throw new Exception?

As Martin already said, I guss this won't work in every case. But at 
least for new code we should go for Exceptions where appropriate.

I'm for example working on a new class to create search fields like the 
new filter above the page tree. This class is throwing exceptions on 
invalid arguments...


HTH
Ingo

P.S. If you think you know places where an Exception would fit better 
than a die(), let us know and provide a patch if possible.




More information about the TYPO3-dev mailing list