|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #52563 error_reporting constant
Submitted: 2010-08-07 19:20 UTC Modified: 2010-12-01 15:31 UTC
Avg. Score:4.7 ± 0.5
Reproduced:3 of 3 (100.0%)
Same Version:3 (100.0%)
Same OS:3 (100.0%)
From: mattgscox at hotmail dot com Assigned:
Status: Wont fix Package: Scripting Engine problem
PHP Version: * OS:
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: mattgscox at hotmail dot com
New email:
PHP Version: OS:


 [2010-08-07 19:20 UTC] mattgscox at hotmail dot com
Feature request only;

For completeness, and coding clarity, please define constant E_NONE to set error reporting to none rather than relying on the absolute integer value of 0

Test script:

Expected result:
[No error warning]

Actual result:
PHP Notice:  Use of undefined constant E_NONE - assumed 'E_NONE'  ....


E_ALL (last revision 2010-08-27 10:52 UTC by
E_NONE (last revision 2010-08-27 10:41 UTC by
E_NONE-and-E_EVERYTHING (last revision 2010-08-10 03:00 UTC by

Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2010-08-08 18:14 UTC]
-Type: Bug +Type: Feature/Change Request
 [2010-08-09 12:39 UTC]
-Status: Open +Status: Assigned -Assigned To: +Assigned To: aharvey
 [2010-08-09 12:45 UTC]
-Status: Assigned +Status: Open -Assigned To: aharvey +Assigned To:
 [2010-08-09 12:45 UTC]
Bah, forgot I don't have karma for Zend. Patch against trunk about to be attached: this seems harmless enough, and a quick Google suggests people do expect this to work.
 [2010-08-09 12:46 UTC]
The following patch has been added/updated:

Patch Name: E_NONE
Revision:   1281350770
 [2010-08-09 19:31 UTC]
While we are at it, we should add an E_ALL constant to -1 to display all errors in the bitfield
 [2010-08-10 04:35 UTC]
It's a shame that E_ALL was changed to not mean "all errors" in the first place, really.

I'll hack up a revised patch (along with an update to the UPGRADING file, since I forgot that first time around) which defines E_EVERYTHING = -1 -- we can bikeshed the exact name on Internals later, if necessary.
 [2010-08-10 05:00 UTC]
The following patch has been added/updated:

Revision:   1281409252
 [2010-08-24 18:44 UTC]
Frankly, I don't see why we need a constant meaning 0. What's wrong with, say... 0?
 [2010-08-27 12:41 UTC]
The following patch has been added/updated:

Patch Name: E_NONE
Revision:   1282905701
 [2010-08-27 12:52 UTC]
The following patch has been added/updated:

Patch Name: E_ALL
Revision:   1282906379
 [2010-08-27 12:53 UTC]
Updated the E_NONE patch to include mentioning the new constant in

Also added a requested patch to alter E_ALL to actually include all error
reporting levels again, rather than excluding E_STRICT.
 [2010-12-01 15:30 UTC]
-Summary: [Feature request] error_reporting constant +Summary: error_reporting constant
 [2010-12-01 15:31 UTC]
-Status: Open +Status: Wont fix -Package: PHP options/info functions +Package: Scripting Engine problem -Operating System: Any +Operating System: -PHP Version: Irrelevant +PHP Version: *
 [2010-12-01 15:31 UTC]
Considered -> declined.
 [2012-03-02 15:38 UTC]
Why was this denied? Reasons given here and at #16330 seem logical and in line with best practice.
PHP Copyright © 2001-2022 The PHP Group
All rights reserved.
Last updated: Thu May 19 19:04:05 2022 UTC