|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2006-10-20 17:00 UTC] hannes dot magnusson at gmail dot com
Description:
------------
call_user_func()/array_walk() doesn't accept
array($obj, "func") callback anymore...
(See Zend/tests/bug31720.phpt && Zend/tests/bug19859.phpt)
Reproduce code:
---------------
<?php
$array = array('at least one element');
array_walk($array, array($nonesuchvar,'show'));
?>
Expected result:
----------------
Notice: Undefined variable: nonesuchvar in %s on line %d
Notice: Non-callable array passed to zend_call_function()
in %s on line %d
Warning: array_walk(): Unable to call Array() - function
does not exist in %s on line %d
Actual result:
--------------
Notice: Undefined variable: nonesuchvar
in /usr/src/php/6.0/Zend/tests/bug31720.php on line 4
Warning: array_walk() expects parameter 2 to be valid
callback, array given
in /usr/src/php/6.0/Zend/tests/bug31720.php on line 4
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Dec 02 02:00:01 2025 UTC |
ext/standard/tests/general_functions/bug35229.php #0 0x083aaf1e in zend_call_function (fci=0xbfbfd010, fci_cache=0xbfbfd000, tsrm_ls=0x85742e0) at /usr/src/php/6.0/Zend/zend_execute_API.c:957 #1 0x082a3082 in zif_call_user_func (ht=31, return_value=0x87f395c, return_value_ptr=0x0, this_ptr=0x0, return_value_used=0, tsrm_ls=0x85742e0) at /usr/src/php/6.0/ext/standard/basic_functions.c:5030 #2 0x083e9da1 in zend_do_fcall_common_helper_SPEC (execute_data=0xbfbfd170, tsrm_ls=0x85742e0) at zend_vm_execute.h:209 #3 0x083ef52c in ZEND_DO_FCALL_SPEC_CONST_HANDLER (execute_data=0xbfbfd170, tsrm_ls=0x85742e0) at zend_vm_execute.h:1648 #4 0x083e98d1 in execute (op_array=0x87f19c8, tsrm_ls=0x85742e0) at zend_vm_execute.h:92 #5 0x083bee9e in zend_execute_scripts (type=8, tsrm_ls=0x85742e0, retval=0x0, file_count=3) at /usr/src/php/6.0/Zend/zend.c:1616 #6 0x08356e16 in php_execute_script (primary_file=0xbfbfe900, tsrm_ls=0x85742e0) at /usr/src/php/6.0/main/main.c:1922 #7 0x084382f3 in main (argc=2, argv=0xbfbfe974) at /usr/src/php/6.0/sapi/cli/php_cli.c:1119