Anonymous functions are not converted correctly.
This:
$exceptions = array_reduce($types, function (&$result, $item) {
$result[] = $item['path'];
return $result;
}, $default_exceptions);
Results into this:
$exceptions = array_reduce($types, ($result $item){
$result[] = $item['path']
$result
}, $default_exceptions);
Which has several syntax errors.