#50329 [Opn->Bgs]: should be false

From: Date: Mon, 30 Nov 2009 12:31:23 +0000
Subject: #50329 [Opn->Bgs]: should be false
References: 1  Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-3365@lists.php.net to get a copy of this message
ID: 50329 Updated by: rquadling@php.net Reported By: bugzilla33 at gmail dot com -Status: Open +Status: Bogus Bug Type: Documentation problem Operating System: win32 7 PHP Version: 5.3.1 New Comment: The documentation is correct. PHP < 4.2.0 Null is returned on failure. PHP >= 4.2.0 False is returned on failure. Note the use of the words "Prior to PHP 4.2.0". Previous Comments: ------------------------------------------------------------------------ [2009-11-30 12:30:51] rquadling@php.net The documentation is correct. PHP < 4.2.0 Null is returned on failure. PHP >= 4.2.0 False is returned on failure. Note the use of the words "Prior to PHP 4.2.0". ------------------------------------------------------------------------ [2009-11-30 09:36:04] bugzilla33 at gmail dot com Description: ------------ bug in manual Reproduce code: --------------- --- From manual page: function.array-search#Changelog --- Expected result: ---------------- 4.2.0 Prior to PHP 4.2.0, array_search() returns NULL on failure instead of FALSE. Actual result: -------------- PHP 5.3.1 returns FALSE on failure, no NULL <? var_dump(array_search('x',array('a'=>'a','b'=>'b','c'=>'c','d'=>'d'))); ?> ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=50329&edit=1

« previous php.doc.bugs (#3365) next »