Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:87792 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 62349 invoked from network); 19 Aug 2015 11:15:24 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 19 Aug 2015 11:15:24 -0000 Received: from [127.0.0.1] ([127.0.0.1:18314]) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ECSTREAM id 81/D3-54915-C4564D55 for ; Wed, 19 Aug 2015 07:15:24 -0400 Authentication-Results: pb1.pair.com header.from=bjorn.x.larsson@telia.com; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=bjorn.x.larsson@telia.com; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain telia.com from 81.236.60.154 cause and error) X-PHP-List-Original-Sender: bjorn.x.larsson@telia.com X-Host-Fingerprint: 81.236.60.154 v-smtpout1.han.skanova.net Received: from [81.236.60.154] ([81.236.60.154:35621] helo=v-smtpout1.han.skanova.net) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id CE/33-54915-D7254D55 for ; Wed, 19 Aug 2015 05:55:10 -0400 Received: from [172.20.10.4] ([95.195.195.61]) by cmsmtp with SMTP id S05JZGAU99HQVS05KZobCs; Wed, 19 Aug 2015 11:55:06 +0200 To: PHP internals References: <20150817123142.13418f26@csystems> <20150817131900.66906015@csystems> <55D1EE8E.9030603@php.net> Cc: Peter Cowburn Message-ID: <55D45278.5050005@telia.com> Date: Wed, 19 Aug 2015 11:55:04 +0200 User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.1.0 MIME-Version: 1.0 In-Reply-To: Content-Type: multipart/alternative; boundary="------------070402070702040007080207" X-CMAE-Envelope: MS4wfMMB1qR6wuZ/3Ic9GlFM0wsJYfXDY6oEyf93Dv0ISr8K6JB4pypaLrjdwsew+GZvz7WhR//1yOmS4SuHH0Qgvecp0S1T8rgaOJ+w0jEmTjnk1KjUhBbW84Z7/QHbGjrgPN2vigU9z6Ga0SwXQwQka/E4zD0GFlG3e2sP7j+QQneIbvOjRckmy6Wov7J23xreQVc57JxPKgAtEy/h22L5A/Qh+e6UJ2ZDP7M1QWPzHdFw Subject: Re: [PHP-DEV] set_exception_handler catches all Throwables From: bjorn.x.larsson@telia.com (=?UTF-8?Q?Bj=c3=b6rn_Larsson?=) --------------070402070702040007080207 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Den 2015-08-19 kl. 10:52, skrev Peter Cowburn: > On 17 August 2015 at 15:24, Sebastian Bergmann wrote: > >> Am 17.08.2015 um 16:00 schrieb Derick Rethans: >>> Actually, I don't call this intended. This is just as much as a BC break >>> as the original implementation where Errors where also Exceptions. IMO, >>> set_exception_handler() should be changed - with my preference it not >>> capturing Error, and instead have an additional set_throwable_handler(). >> +1 >> > What's the plan for set_exception_handler() regarding Throwables? Seeing as > we're now in the RC release phase I think this bone of contention should be > resolved one way or another as soon as we can. Yes, a "global" function that behaves differently between PHP 5 & 7 is not optimal in my view. I'm also wondering how to make one handler managing two different type of situations. @ircmaxwell described it in *Core functions throwing exceptions in PHP7*: "Errors signify programmer error, where Exceptions signify unknown or runtime errors. Meaning that an Error should always be a problem with your code, but an Exception could be a systems problem, a user problem or a problem in your code." /Cheers //Björn Larsson/ PS A bit new to this list but hope to have contributed a little :) --------------070402070702040007080207--