ID:               43142
 Updated by:       [EMAIL PROTECTED]
 Reported By:      felipensp at gmail dot com
-Status:           Open
+Status:           Bogus
 Bug Type:         Scripting Engine problem
 Operating System: Linux
 PHP Version:      5.3CVS-2007-10-30 (snap)
 New Comment:

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

Mind the 12 as length of oyur output - the actual name of the lambda
function is "\0lambda_1" but your terminal/browser doesn't dispaly the
null byte.



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

[2007-10-30 13:07:53] felipensp at gmail dot com

Description:
------------
Return of create_function() concat. with 'foo'.
But, when calling the function with the name of variable's value, only
'foo' is used...

Reproduce code:
---------------
<?php

$a = 'foo'. create_function('', 'print "foo!";');

var_dump($a); // string(12) "foolambda_1"

function foo() { print 1; }

$a();         // Fatal error: Call to undefined function foo()

// foo() ?!


Expected result:
----------------
Fatal error: Call to undefined function foolambda_1()

Actual result:
--------------
string(12) "foolambda_1"

Fatal error: Call to undefined function foo()


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


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

Reply via email to