Re: Default exception handler

From: Date: Sat, 06 Sep 2003 21:10:36 +0000
Subject: Re: Default exception handler
References: 1 2 3 4 5 6 7  Groups: php.internals 
Request: Send a blank email to internals+get-4418@lists.php.net to get a copy of this message
Hello Zeev, Saturday, September 6, 2003, 10:52:40 PM, you wrote: > At 20:20 06/09/2003, Sebastian Bergmann wrote: >> * Introduce >> >> interface Throwable {} >> [...] > I don't see any advantage to that at all. Either exceptions inherit from > exception or not, there's no reason to complicate things with a new > interface. We don't have different kinds of throwables, so doing that > appears to be pure mental overhead. I also failed to understand why > modules would not want to inherit the basic Exception class. If the > exception is not supposed to be caught in user space, why throw it? If you > can recover, recover now, or bail out (or both). > Marcus - I don't see the problem having people write catch (Exception $foo) > instead of catch ($foo). Our object orientation has become more strict > than structured PHP already. Making exceptions more PHPish by introducing > new terms and requirements appears to defeat the purpose. Well let's give it a rest. I must agree that it works fine the way it is and we do not need to support more syntax abbrevations/lazyness or make it more compley and hence more difficult to understand for the user. -- Best regards, Marcus mailto:helly@php.net

« previous php.internals (#4418) next »