ID:          46354
 Updated by:  [EMAIL PROTECTED]
-Summary:     Array_key_exists vs. ArrayObject
 Reported By: david at grudl dot com
-Status:      Open
+Status:      Bogus
 Bug Type:    SPL related
 PHP Version: 5.3CVS-2008-10-21 (snap)
 New Comment:

Expected behaviour, object is not an array.


Previous Comments:
------------------------------------------------------------------------

[2008-10-21 08:18:02] david at grudl dot com

Description:
------------
Array_key_exists accepts ArrayObject since PHP 5.0.0, but 5.3.0 refuse
it. Feature or bug?

Reproduce code:
---------------
$arr = array('a' => 10);

$obj = new ArrayObject($arr);

echo array_key_exists('a', $obj);


Expected result:
----------------
TRUE

Actual result:
--------------
Warning: array_key_exists() expects parameter 2 to be array, object
given
NULL


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=46354&edit=1

Reply via email to