Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:86385 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 38904 invoked from network); 25 May 2015 18:03:14 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 25 May 2015 18:03:14 -0000 Authentication-Results: pb1.pair.com header.from=rowan.collins@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=rowan.collins@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.212.181 as permitted sender) X-PHP-List-Original-Sender: rowan.collins@gmail.com X-Host-Fingerprint: 209.85.212.181 mail-wi0-f181.google.com Received: from [209.85.212.181] ([209.85.212.181:38870] helo=mail-wi0-f181.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 07/70-36604-2E363655 for ; Mon, 25 May 2015 14:03:14 -0400 Received: by wichy4 with SMTP id hy4so55824477wic.1 for ; Mon, 25 May 2015 11:03:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:content-type:content-transfer-encoding; bh=xVoL/7AXhZlBZubR+gox/CFoTE1oSNmMwCwDBU4AE20=; b=zZyoGJ/ruU1/tvJoL1SsIK4K0PtL1s/WMRwdrh3rlF5lLhsMFkMcQQTr1ESD62iphB 8nmZPxtXHZlzYBGyqE3i03arNSI7qCbjWuelSR2pSfshripe9vGRPX3vbXm+8vsmavI8 n/B2FeBVLsLYiI7puf91ZOb1XDsPtJ3VzV4QplTzy+fMA9yZpwzc0AG2zF/lbWzmxDW8 jE79JFx7D7IZH3x6KEkd12msAiuNjhpp1WgknJwDARsruCqjOoGOjE92nVqvx7syn3Ur shqvZE4UneiurI4Q2bYpKtqSasgVnKr37hDIq2YYIsI1ZW766i4DhfFMfgATU0uBZAwH H51Q== X-Received: by 10.194.203.138 with SMTP id kq10mr40861024wjc.124.1432576991965; Mon, 25 May 2015 11:03:11 -0700 (PDT) Received: from [192.168.0.5] (cpc68956-brig15-2-0-cust215.3-3.cable.virginm.net. [82.6.24.216]) by mx.google.com with ESMTPSA id z12sm17870100wjq.12.2015.05.25.11.03.10 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 25 May 2015 11:03:10 -0700 (PDT) Message-ID: <556363D3.1040902@gmail.com> Date: Mon, 25 May 2015 19:02:59 +0100 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: internals@lists.php.net References: <971AB39D-1E20-43E8-9CF1-A7F67E3C14C3@icicle.io> In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] [RFC] Throwable Interface From: rowan.collins@gmail.com (Rowan Collins) On 24/05/2015 22:32, Yasuo Ohgaki wrote: > Does this include internal function type errors? > e.g. > > $ php -r 'var_dump(mt_srand("99999999999999999999999999999999999"));' > PHP Warning: mt_srand() expects parameter 1 to be integer, string given in > Command line code on line 1 > NULL > > If not, please make these exceptions rather than E_WARNING. > We need consistency here. Changing a Warning to an Exception is a much bigger deal than changing an Error to an Exception. While an Exception *can* be caught, the fundamental nature of it is that it is *fatal* if it is not caught. So you would be changing an advisory warning to a fatal error. There might be cases where this would be sensible, but this has nothing to do with a) changing Errors to Exceptions (which has already passed) or b) changing the hierarchy to add a Throwable interface (the subject of this thread). Regards, -- Rowan Collins [IMSoP]