Re: [VOTE] Exceptions in the engine
| From: | Rowan Collins | Date: | Sat, 16 May 2015 20:14:58 +0000 |
| Subject: | Re: [VOTE] Exceptions in the engine | ||
| References: | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-86262@lists.php.net to get a copy of this message | ||
On 16/05/2015 19:44, Levi Morrison wrote:
On Sat, May 16, 2015 at 12:28 PM, Stanislav Malyshev <smalyshev@gmail.com> wrote:Do you agree with these statements? - There is no exception which a program using "catch ( Exception $e )" will catch under PHP 5 but not under PHP 7 (with BaseException/Throwable as proposed). - There is no fatal error which becomes non-fatal for such a program, because they will become uncaught EngineExceptions, and failure to catch an exception is a fatal error. - There is no non-fatal error which becomes fatal for such a program, because EngineExceptions exist only where there were already fatal errors. Leaving aside "definitions" and "semantics", where, then, is the BC break? Regards, -- Rowan Collins [IMSoP]Hi!You are incorrect. The set of exceptions thatThere's nothing that prevents us from reneging on that by another vote. If it's a bad decision backed by logical arguments then we canThat's a pretty big if, given that your only argument - that it is a BC break - is incorrect, as in fact the set of exceptions caught before and after change is exactly the same, and the only difference is that in the new code, you can *also* catch errors, the option that you didn't have before. Absent that argument, there's no reason to renege.catch (Exception)catches is all exceptions by its definition. By altering it to no longer include all exceptions means the semantics of it changed.