From a2a469fd5f2f9bdad5ef5d314d543daa4326b648 Mon Sep 17 00:00:00 2001 From: Friedhelm Betz <betz@php.net> Date: Sun, 7 Dec 2003 16:04:36 +0000 Subject: [PATCH] real bugfix #26472 E_STRICT available with PHP5 git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@145881 c90b9560-bf6c-de11-be94-00142212c4b1 --- reference/errorfunc/constants.xml | 28 ++++++++++--------- .../errorfunc/functions/error-reporting.xml | 18 ++++++------ reference/errorfunc/ini.xml | 27 ++++++++++-------- 3 files changed, 40 insertions(+), 33 deletions(-) diff --git a/reference/errorfunc/constants.xml b/reference/errorfunc/constants.xml index 05140e3908..04d29b0f87 100644 --- a/reference/errorfunc/constants.xml +++ b/reference/errorfunc/constants.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.9 $ --> +<!-- $Revision: 1.10 $ --> <section id="errorfunc.constants"> &reftitle.constants; &extension.constants.core; @@ -172,6 +172,20 @@ <entry>PHP 4 only</entry> </row> + <row id="e-all"> + <entry>2047</entry> + <entry> + <constant>E_ALL</constant> + (<type>integer</type>) + </entry> + <entry> + All errors and warnings, as supported, except of level + <constant>E_STRICT</constant>. + </entry> + <entry></entry> + </row> + + <row id="e-strict"> <entry>2048</entry> <entry> @@ -186,18 +200,6 @@ <entry>PHP 5 only</entry> </row> - <row id="e-all"> - <entry>4095</entry> - <entry> - <constant>E_ALL</constant> - (<type>integer</type>) - </entry> - <entry> - All errors and warnings, as supported. - </entry> - <entry>With PHP >= 5.0.0 the value changed from 2047 to 4095.</entry> - </row> - </tbody> </tgroup> </table> diff --git a/reference/errorfunc/functions/error-reporting.xml b/reference/errorfunc/functions/error-reporting.xml index 679778ebde..56eef38b44 100644 --- a/reference/errorfunc/functions/error-reporting.xml +++ b/reference/errorfunc/functions/error-reporting.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.6 $ --> +<!-- $Revision: 1.7 $ --> <!-- splitted from ./en/functions/errorfunc.xml, last change in rev 1.1 --> <refentry id="function.error-reporting"> <refnamediv> @@ -142,18 +142,18 @@ ini_set ('error_reporting', E_ALL); <link linkend="e-user-error">E_USER_NOTICE</link> </entry> </row> + <row> + <entry>2047</entry> + <entry> + <link linkend="e-all">E_ALL</link> + </entry> + </row> <row> <entry>2048</entry> <entry> <link linkend="e-strict">E_STRICT</link> </entry> </row> - <row> - <entry>4096</entry> - <entry> - <link linkend="e-all">E_ALL</link> - </entry> - </row> </tbody> </tgroup> </table> @@ -161,8 +161,8 @@ ini_set ('error_reporting', E_ALL); <warning> <simpara> With PHP > 5.0.0 <constant>E_STRICT</constant> with value 2048 is - introduced. Therefore the value for <constant>E_ALL</constant> changed - to 4096. + available. <constant>E_ALL</constant> does <emphasis>NOT</emphasis> + include error level<constant>E_STRICT</constant>. </simpara> </warning> <para> diff --git a/reference/errorfunc/ini.xml b/reference/errorfunc/ini.xml index 63adf322a3..a52ca7f422 100644 --- a/reference/errorfunc/ini.xml +++ b/reference/errorfunc/ini.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.15 $ --> +<!-- $Revision: 1.16 $ --> <section id="errorfunc.configuration"> &reftitle.runtime; &extension.runtime; @@ -17,7 +17,7 @@ <tbody> <row> <entry>error_reporting</entry> - <entry>E_ALL & ~E_NOTICE & ~E_STRICT</entry> + <entry>E_ALL & ~E_NOTICE</entry> <entry>PHP_INI_ALL</entry> </row> <row> @@ -122,15 +122,9 @@ <link linkend="ini.display-errors">display_errors</link> directive. </para> <para> - In PHP 4 the default value is E_ALL & ~E_NOTICE. This setting does - not show <constant>E_NOTICE</constant> level errors. You may want to - show them during development. - </para> - <para> - In PHP 5 <constant>E_STRICT</constant> is introduced. The default value - is E_ALL & ~E_NOTICE & ~E_STRICT. This setting does not show - errors <constant>E_NOTICE</constant> and <constant>E_STRICT</constant> - level errors. You may want to show them during development. + In PHP 4 and PHP 5 the default value is E_ALL & ~E_NOTICE. This + setting does not show <constant>E_NOTICE</constant> level errors. You + may want to show them during development. </para> <note> <para>Enabling <constant>E_NOTICE</constant> during development has @@ -143,6 +137,17 @@ it is a string index for the array. </para> </note> + <note> + <para> + In PHP 5 a new error level <constant>E_STRICT</constant> is available. + As <constant>E_STRICT</constant> is not included within + <constant>E_ALL</constant> you have to explicitly enable this kind of + error level. Enabling <constant>E_STRICT</constant> during development + has some benefits. STRICT messages will help you to use the latest and + greatest suggested method of coding, for example warn you about using + deprecated functions. + </para> + </note> <para> In PHP 3, the default setting is <literal>(E_ERROR | E_WARNING | E_PARSE)</literal>,