I just realized that a little PHP does not work correctly on one server, but it works on another.
They both run Ubuntu 10.04 with PHP PHP 5.3.2 (PHP 5.3.2-1ubuntu4.2 with Suhosin-Patch (cli) (built: May 13, 2010 20:03:45))
I am testing using:
$f = function() {};
var_dump($f);
die();
On a server that is running, the result is:
object (close) # 1 (0) {}
In one that does not, the result is:
UNKNOWN: 0
What am I missing?
[edit]
It seems that the problem is related to having 2 closures in one file:
<?php
$f = function() {};
$f2 = function() {};
var_dump($f);
var_dump($f2);
die();
Outputs:
UNKNOWN: 0
object (Closure) # 1 (0) {}
source
share