[eluser]xwero[/eluser]
I think you are staring too much at the first example, we established it's a bad one. But if you look at the second one if you would do that in plain php if would be something like
Code:
$array = array(7);
function add_3($x)
{
return $x += 3;
}
function alter_value(&$y, $key, $function)
{
$y = $function($y) + $function($y);
}
array_walk($array,'alter_value','add_3');
So it is an enchantment but i still have no idea where it could be useful in real world apps.