With the "callable" concept i meant, that many things are seen as callable:
[$obj, "methodName"] => callable for $obj->methodName()
"str_replace" => callable for function "str_replace"
["ClassName", "staticMethod"] => callable for ClassName::staticMethod()
"ClassName::staticMethod" => callable for ClassName::staticMethod()
function() {} => callable for a lambda
I would prefer a "ClassMethod" and a "Function" type, instead of using strings.
$x = phpinfo; $x();
$y = $obj->method; $y();
But i don't think, this is possible, because PHP supports global constants and function names cannot be distinguished from constants, especially because PHP is not case sensitive regarding functions and classnames.
But I see, that my karma has decreased with this post, so it seems, that not many are in my opinion...
For at nearly 10 years now PHP has had support for lambdas, meaning for most uses `$foo()` can be used instead and with the inclusion of the spread operator it's seldom used.