Re: svn: /phpdoc/en/trunk/language/predefined/ errorexception.xml

From: Date: Thu, 05 Mar 2015 11:06:44 +0000
Subject: Re: svn: /phpdoc/en/trunk/language/predefined/ errorexception.xml
References: 1 2  Groups: php.doc.cvs 
Request: Send a blank email to doc-cvs+get-13126@lists.php.net to get a copy of this message
Hi, On Thu, Mar 5, 2015 at 7:29 PM, Peter Cowburn <petercowburn@gmail.com> wrote: > > > On 5 March 2015 at 09:13, TAKAGI Masahiro <takagi@php.net> wrote: >> >> takagi Thu, 05 Mar 2015 09:13:29 +0000 >> >> Revision: >> http://svn.php.net/viewvc?view=revision&revision=336038 >> >> Log: >> Example #1: correct the order of parameters > > > I have reverted this commit. Passing $errno as the $severity argument (the > 3rd parameter) is deliberate and should stay. The "severity" is a property > specific to ErrorException, which is not present in other Exceptions, and is > designed to map to our E_* constants. > >> >> >> $errno should be the 2nd parameter. > > > We *may* want to also pass $errno as the $code argument. That's up for > debate. This is also not the first time that the $code and $severity > arguments have been swapped around in that example; I can only attribute > this as a failing in the current documentation in making it abundantly clear > what the ErrorException::$severity is meant to represent. > >> >> >> Bug: https://bugs.php.net/1 (Not a bug) Apache 1.3b3 + >> mod_php3 is slow >> >> Changed paths: >> U phpdoc/en/trunk/language/predefined/errorexception.xml >> >> Modified: phpdoc/en/trunk/language/predefined/errorexception.xml >> =================================================================== >> --- phpdoc/en/trunk/language/predefined/errorexception.xml 2015-03-04 >> 22:37:26 UTC (rev 336037) >> +++ phpdoc/en/trunk/language/predefined/errorexception.xml 2015-03-05 >> 09:13:29 UTC (rev 336038) >> @@ -88,7 +88,7 @@ >> // This error code is not included in error_reporting >> return; >> } >> - throw new ErrorException($errstr, 0, $errno, $errfile, $errline); >> + throw new ErrorException($errstr, $errno, 0, $errfile, $errline); >> } >> set_error_handler("exception_error_handler"); >> >> >> >> -- >> PHP Documentation Commits Mailing List (http://www.php.net/) >> To unsubscribe, visit: http://www.php.net/unsub.php > > -- TAKAGI Masahiro mailto:matakagi@gmail.com

« previous php.doc.cvs (#13126) next »