When using a framework, it's often the case that you can somehow reference a class name in a configuration - often you can also reference a method.
$setting = [
'controller' => DemoController::class,
'action' => 'demoAction', // how to reference this?
];
A class is referenced by ::class. The big advantage comes when it comes to refactoring because a reference can be better refactored than a simple "string".
But if you want to apply the whole thing to methods, the question arises, how can you reference a method in such a way that the same possibility arises.
Is there already a corresponding approach or even a solution for this?
i.e. -> when using a "reference" for a class - and this class will be declared as "deprecated" then each usage of this class will be marked with a stroke:
The same behavior is missing wenn you only use a string. This is my point. the reference via string is no "real" reference.
