Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:70543 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 99462 invoked from network); 9 Dec 2013 07:30:46 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 9 Dec 2013 07:30:46 -0000 Authentication-Results: pb1.pair.com header.from=dmitry@zend.com; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=dmitry@zend.com; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain zend.com from 74.125.82.177 cause and error) X-PHP-List-Original-Sender: dmitry@zend.com X-Host-Fingerprint: 74.125.82.177 mail-we0-f177.google.com Received: from [74.125.82.177] ([74.125.82.177:46989] helo=mail-we0-f177.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 14/71-23208-5A175A25 for ; Mon, 09 Dec 2013 02:30:45 -0500 Received: by mail-we0-f177.google.com with SMTP id u56so2948454wes.8 for ; Sun, 08 Dec 2013 23:30:41 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=l+cElkbINgoARLr3oGuT/qolR9InoeaHQp8L2ruNJqE=; b=P4virnxD8WwmW7vazTEennAfU1lcWsHeQo4SKluBdYXHUgkYGaZXVJBwFrOODcScA0 qy5PutHrY8ouDWKlNfCu16GTjwxv6/8yjtbt7R1U+AZNbVq95c8GJTvtMANXWjcg4ME9 CuUy9DixPN8hhRYq9e+I/ZdIM6WiQ9i05vGDRedC3VHr0uZkM01iyDrhdO4I4IP+3D2g QIQdx3f+LYcO5cEXRawBExk4fXOmPbRd1mkpzOinwtLOcvSl0xOSFvzlXtSWN4QWTeKn J9GbkyDJtei+K5JahnLATyD37oxIDpIghL6nBRvMZ5iV/IZevW/J1StlNQRbJHx44Xym Y1ow== X-Gm-Message-State: ALoCoQn8s78m/oeyXQPE7mBAE9dRKLrCbmbGVhT0HNNmDs+Q/HgX116JIJdNXzcCN4y5Fi4u6sxIwywM67IaBG3lHIx+ddjLO8uqnEapwWIr2kA96/60ey9rjd6yb9TAWaH3TkL/961u MIME-Version: 1.0 X-Received: by 10.194.5.7 with SMTP id o7mr13974970wjo.17.1386574241344; Sun, 08 Dec 2013 23:30:41 -0800 (PST) Received: by 10.227.91.198 with HTTP; Sun, 8 Dec 2013 23:30:41 -0800 (PST) In-Reply-To: References: Date: Mon, 9 Dec 2013 11:30:41 +0400 Message-ID: To: Nikita Popov Cc: PHP internals Content-Type: multipart/alternative; boundary=047d7b5d8d451c425304ed14f927 Subject: Re: [PHP-DEV] [VOTE] Allowing use of exceptions in the engine From: dmitry@zend.com (Dmitry Stogov) --047d7b5d8d451c425304ed14f927 Content-Type: text/plain; charset=UTF-8 Hi Nikita, The idea makes sense, but it really changes the fundamental design decision. For now the patch misses more than 300 places where you'll have to find a way to recover from a error state. As you said, it's hardly possible in some cases (e.g. memory_limit overflow). Anyway, I'm not sure if the effort and risks of bugs and breaks cost the ability of writing "dirty" code. Thanks. Dmitry. On Sat, Dec 7, 2013 at 4:57 PM, Nikita Popov wrote: > Hi internals! > > I opened the vote on the "Exceptions in the engine" RFC: > > https://wiki.php.net/rfc/engine_exceptions#vote > > The vote has three options, "Yes", "No" and "Yes, without > E_RECOVERABLE_ERROR changes". The last option is a version of the proposal > without BC issues. > > Some further notes: > * I will not be including something like BaseException. Introducing it for > this purpose seems like bad design and will be very hard to get rid of in > the future. As the proposal (without recoverable errors) does not break BC > [1] even without it, I don't see a reason to introduce it. > * Some people suggest to use different subclasses of EngineException for > different error types. I'm not against that, but I think it's okay to do > that in a separate proposal, if someone can come up with a good selection > of exception classes. It's much easier (and does not break BC) to add > subclassing later, than to add suboptimal subclass types now and try to fix > something like the SPL exception mess later. > * The suggested uncaught exception error message change is just a bit of > cosmetics (and not directly related to this proposal), so I'd like to do > that separately. > > And regarding the vote: If you are in favor of the proposal in general, but > want to have it in PHP 6 rather than PHP 5.6, then vote "No" here. If it > fails now, someone can revive this once the time for PHP 6 has come. > > Thanks, > Nikita > > [1]: We don't have a formal definition for this, but it seems to be general > consensus that relaxing error conditions does not constitute a backwards > compatibility break. > --047d7b5d8d451c425304ed14f927--