Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:78818 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 51031 invoked from network); 6 Nov 2014 14:22:41 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 6 Nov 2014 14:22:41 -0000 Authentication-Results: pb1.pair.com smtp.mail=tyra3l@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=tyra3l@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.214.171 as permitted sender) X-PHP-List-Original-Sender: tyra3l@gmail.com X-Host-Fingerprint: 209.85.214.171 mail-ob0-f171.google.com Received: from [209.85.214.171] ([209.85.214.171:38019] helo=mail-ob0-f171.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id B3/76-28384-F248B545 for ; Thu, 06 Nov 2014 09:22:39 -0500 Received: by mail-ob0-f171.google.com with SMTP id wp18so901910obc.16 for ; Thu, 06 Nov 2014 06:22:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=17TYv3nzy7aZBRPkUTbYvVArcW6b378zqx28S+a3bKM=; b=FCQnn0dlA1Wa5H2Mwobut8Rd2TGyyhTzruPUR97BtnyP+Cl/Tr4LzbjNoiVxWNawZ0 IS3zBl4qE3lCCWrR6rZ6qF5mVkcid3GTeUCMtcYNuvTsdf+ktjTmJzMh2O+rcpbyFaJ6 23SDRjpKTV6zc+KM3JIlIbctxQqvxE0CoC+Tgkk+deXIuh4jMufBgGhbF6NuzKukLYY4 L949QIC+Pa4xTlfI6ShJjp5FYPMwvm43agNKvo2P/EtD/HD+w56HvcPQplD8wNiYjOrM R+nYP1b0wsr8hTR1cVdPefvYGeMzyV1MokN85eFadj6dpi8AGokBJHWMVgxZevvgnxdb sZLw== MIME-Version: 1.0 X-Received: by 10.202.64.10 with SMTP id n10mr1612463oia.98.1415283756566; Thu, 06 Nov 2014 06:22:36 -0800 (PST) Received: by 10.60.116.39 with HTTP; Thu, 6 Nov 2014 06:22:36 -0800 (PST) In-Reply-To: <545B7871.2010502@gmx.de> References: <3E2593DC-5755-48A6-8802-6F2FB3625778@ajf.me> <04723EAD-4C8E-41C2-BE81-4989882A0C69@ajf.me> <545B26BB.9020406@lsces.co.uk> <545B589A.4010606@gmx.de> <545B7871.2010502@gmx.de> Date: Thu, 6 Nov 2014 15:22:36 +0100 Message-ID: To: Christoph Becker Cc: Lester Caine , PHP Internals Content-Type: multipart/alternative; boundary=001a113d769a9121af0507316dd7 Subject: Re: [PHP-DEV] Thresholds of backwards compatibility breaks From: tyra3l@gmail.com (Ferenc Kovacs) --001a113d769a9121af0507316dd7 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On Thu, Nov 6, 2014 at 2:32 PM, Christoph Becker wrote: > Ferenc Kovacs wrote: > > > On Thu, Nov 6, 2014 at 12:16 PM, Christoph Becker > wrote: > > > >> Lester Caine wrote: > >> > >>> Yes it is only a number, but a lot more problematic changes WERE push= ed > >>> through across those three versions which would have been much safer > >>> handled by removing e_strict from PHP5.4 rather than trying to live > with > >>> both versions of PHP. > >> > >> I don't see a problem with regard to E_STRICT. If your code is not ye= t > >> strict compliant, simply turn it off for error_reporting: > >> > >> error_reporting =3D E_ALL & ~E_STRICT > >> > >> -- > >> Christoph M. Becker > > > > for the record, see https://bugs.php.net/bug.php?id=3D65322 and the iss= ued > > linked from that. > > turned out that we had a bug, which prevented the autoload calls inside > an > > error handler call when the original error was a compile time one. > > we have some compile time strict errors about abstract classes which > could > > have triggered hard-to-debug fatal errors for people(with custom error > > handlers which depend on dynamic auto loading) when we made E_STRICT pa= rt > > of E_ALL in 5.4. > > Thanks for pointing this out -- I have not been aware of the issue. Of > course, having had this bug for such a long time is unfortunate, but it > seems to me a viable userland workaround for not yet "strict" code to > support affected PHP versions would be to pass an appropriate > $error_types argument to the set_error_handler call, e.g. > > set_error_handler('my_error_handler', E_ALL & ~E_STRICT); > > -- > Christoph M. Becker > > the bug is already fixed by Nikita, I only brought it up, as an example that migrating to 5.4 and the fact that we included E_STRICT to E_ALL could indeed cause fatal errors for some application. ofc after you realize the issue, there were a couple of ways to mitigate it (the easiest is to change your php.ini to remove E_STRICT from error_reporting or changing your error handler to not care about these kind of errors or to not depend on the availability of your autoloader). --=20 Ferenc Kov=C3=A1cs @Tyr43l - http://tyrael.hu --001a113d769a9121af0507316dd7--