Open anneetien opened 1 year ago
I cannot find #deadCode in Moose 11. But we have #isDead that is implemented using the MM and MooseQuery. It checks if it has an incoming dependency and returns true only if there is none.
Is it still valid?
your are asking if the issue or the method #isDead is still valid ?
May be we can rename #isDead to #hasNoIncoming or #hasNoClient ... ?
And for a real dead code detection, we need a more complex implementation. This calls for "complex" queries or algorithms that would be reusable but that would need fine tuning for specific meta-models or even specific applications (for example how to detect that a service in a client/server application is or not dead?)
The way deadCode is computed (taking into account the superClasses and implementing interfaces) is not well done. We have to imprive it. We have to deal also with methods with parameterized parameters. After we will have to deal also with dead branch.