I know that functions can be called dynamically, but is there a way to determine statically which functions (and methods of ObjC objects) are not being called?
I'm not sure that this is a sensible thing for someone to have attempted to make such a static analysis tool - it would be very complicated, and you would probably find that it would only find trvial examples of functions that would not be called - e.g. functions you've created in your classes, and you have no calls to them. All the stuff that interacts with Cocoa ... well the problem is that they 'might' be called in different circumstances.
In any case, what you should really be interested in is runtime code coverage - as this would show you (with a decent suite of tests) what code is actually being used, which would be a smaller subset.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With