Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:24359 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 11877 invoked by uid 1010); 12 Jul 2006 22:45:55 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 11862 invoked from network); 12 Jul 2006 22:45:55 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 12 Jul 2006 22:45:55 -0000 X-PHP-List-Original-Sender: antony@zend.com X-Host-Fingerprint: 80.74.107.235 mail.zend.com Linux 2.5 (sometimes 2.4) (4) Received: from ([80.74.107.235:30405] helo=mail.zend.com) by pb1.pair.com (ecelerity 2.1.1.3 r(11751M)) with ESMTP id CB/D8-63905-1AB75B44 for ; Wed, 12 Jul 2006 18:45:55 -0400 Received: (qmail 31311 invoked from network); 12 Jul 2006 22:44:58 -0000 Received: from internal.zend.office (HELO ?127.0.0.1?) (10.1.1.1) by internal.zend.office with SMTP; 12 Jul 2006 22:44:58 -0000 Message-ID: <44B57B9C.4000000@zend.com> Date: Thu, 13 Jul 2006 02:45:48 +0400 User-Agent: Thunderbird 1.5.0.4 (X11/20060516) MIME-Version: 1.0 To: Lukas Smith CC: internals@lists.php.net References: <0F.C0.46743.0CB15B44@pb1.pair.com> <44B54CAE.70909@zend.com> <44B579C7.7010103@php.net> In-Reply-To: <44B579C7.7010103@php.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] E_STRICT From: antony@zend.com (Antony Dovgal) On 13.07.2006 02:37, Lukas Smith wrote: > Antony Dovgal wrote: > >> Lukas, I thought we already discussed and agreed that the only >> acceptable solution is NOT to add any E_STRICT messages if the >> recommended way didn't exist in first release of the major version. >> This apparently requires versioning and its support in PEAR. >> And personally I think this is the only solution we can accept. > > That would work fine as I pointed out in the email, but would limit the > scope of E_STRICT. The point of E_STRICT was to quickly let people know > about things that are no longer recommended/have become deprecated. > Waiting until the next major version for new features would diminish that. Well, that's what major versions are for, right? Bugfix releases are for bugfixes, while major versions may introduce new things and features. >> Adding some kind of hypercomplicated API for "filtering" E_STRICT is >> definitely huge overkill. > > Not sure if I explained things this badly. All I requested was that the > error message contain some "header" with the php version that notice was > added. > > This requires no changes in any infrastructure and the point was exactly > to make it feasible to write such a filter function for custom error > handler. The alternative would require keeping an array of the internal > error messages with the version they were added. Which would obviously > break apart if we do a simple language or other change to the given notice. > > So all I am asking is that E_STRICT notices look like the following (or > something of that sort): > > Strict Standards since PHP 5.0.0: Declaration of Europe::get_countries() > should be compatible with that of Scandinavia::get_countries() in - on > line 14 > > Instead of: > > Strict Standards: Declaration of Europe::get_countries() should be > compatible with that of Scandinavia::get_countries() in - on line 14 > > So I dont really see where its killing a fly with a tank either. All > that people then need to do is write a simple regexp, that filters out > the version number in the E_STRICT notice and pass it off to > version_compare(). Very trivial to implement in userland, nothing more > than changing a few strings in PHP core. End of story, problem solved. Sorry, I still fail to see a reason to "filter" error messages.. -- Wbr, Antony Dovgal