Re: In regards to E_STRICT and PHP5
| From: | Jason Garber | Date: | Thu, 16 Jun 2005 20:28:35 +0000 |
| Subject: | Re: In regards to E_STRICT and PHP5 | ||
| References: | 1 2 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-16764@lists.php.net to get a copy of this message | ||
Hello boots,
if(AppDevLevel == 'Production')
{
error_reporting(E_ALL);
}
else
{
error_reporting(E_ALL | E_STRICT);
}
Why don't you implement something like this in your application -
then you CAN control what error level is used at the client site.
--
Best regards,
Jason mailto:jason@ionzoft.com
Thursday, June 16, 2005, 3:09:43 PM, you wrote:
b> --- George Schlossnagle <george@omniti.com> wrote:
>> On Jun 16, 2005, at 2:50 PM, boots wrote:
>> > --- Andi Gutmans <andi@zend.com> wrote:
>> >
>> >> You missed the point of E_STRICT. I introduced it as an
>> E_PEDANTIC.
>> >> That was the whole idea. To be pedantic about code that works,
>> not
>> >> to warn about code that doesn't work (which is for higher warning
>> >> levels)
>> >>
>> >
>> > I don't think I missed that, I just don't appreciate it :)
>>
>> If you don't want pedantic checks, don't run with E_STRICT.
b> As a developer, I want to run with E_STRICT, or at least, I want to
b> know what the engine thinks in regards to the correctness of my code.
b> That is not the problem. The problem is that I can't control what
b> customer environments and I don't necessarily want to port perfectly
b> acceptable PHP4 code to avoid warning on their systems. The point is
b> that E_STRICT is meant for developers but is implemented in the general
b> runtime where it impacts more than just developers.
b> Well, you were all kind enough to allow me to have my say so I will
b> leave it in your capable hands now and accept your decisions.
b> Thank-you.