Doc #65308 [NEW]: register_shutdown_function can take a closure, not just a callback name

From: Date: Mon, 22 Jul 2013 08:07:27 +0000
Subject: Doc #65308 [NEW]: register_shutdown_function can take a closure, not just a callback name
Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-10103@lists.php.net to get a copy of this message
From: fgmarand at gmail dot com Operating system: Linux PHP version: 5.4.17 Package: Documentation problem Bug Type: Documentation Problem Bug description:register_shutdown_function can take a closure, not just a callback name Description: ------------ --- From manual page: http://www.php.net/function.register-shutdown- function#refsect1-function.register-shutdown-function-description --- register_shutdown_function(function () { echo "Hello world\n"; }); This actually works, although the manual has no mention of Closure support. Expected result: ---------------- According to the doc, this should cause an invalid argument error, Actual result: -------------- It works, so it should be documented, since PHP is moving from "function name/array" callbacks to Closures for a number of versions. -- Edit bug report at https://bugs.php.net/bug.php?id=65308&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=65308&r=trysnapshot54 Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=65308&r=trysnapshot53 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=65308&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=65308&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=65308&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=65308&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=65308&r=needscript Try newer version: https://bugs.php.net/fix.php?id=65308&r=oldversion Not developer issue: https://bugs.php.net/fix.php?id=65308&r=support Expected behavior: https://bugs.php.net/fix.php?id=65308&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=65308&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=65308&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=65308&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=65308&r=php4 Daylight Savings: https://bugs.php.net/fix.php?id=65308&r=dst IIS Stability: https://bugs.php.net/fix.php?id=65308&r=isapi Install GNU Sed: https://bugs.php.net/fix.php?id=65308&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=65308&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=65308&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=65308&r=mysqlcfg

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