Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>Rather than my comment, the best approach that I used (and still use) is calling:</p> <pre><code>(void)instrumentObjcMessageSends(YES); </code></pre> <p>When I need to start logging all messages and then:</p> <pre><code>(void)instrumentObjcMessageSends(NO); </code></pre> <p>Don't forget to add <code>#import &lt;objc/runtime.h&gt;</code>.<br/> When I don't need it anymore. The annoying thing is that the log is created under <code>/tmp/msgSends-</code> and this means that you have to open the terminal and use <code>tail</code> to see it in a readable way.</p> <p>What is printed is something like this:</p> <pre><code>- CustomTableViewController UIViewController _parentModalViewController - CustomTableViewController UIViewController isPerformingModalTransition - CustomTableViewController UIViewController setInAnimatedVCTransition: - CustomTableViewController UIViewController viewWillMoveToWindow: - CustomTableViewController UIViewController isPerformingModalTransition - CustomTableViewController UIViewController parentViewController - CustomTableViewController UIViewController _popoverController - CustomTableViewController UIViewController _didSelfOrAncestorBeginAppearanceTransition - CustomTableViewController UIViewController parentViewController - CustomTableViewController UIViewController __viewWillDisappear: - CustomTableViewController UIViewController _setViewAppearState:isAnimating: - CustomTableViewController UIViewController automaticallyForwardAppearanceAndRotationMethodsToChildViewControllers </code></pre> <p>Note: It has been a while since I used this approach for the last time and it looks like this approach doesn't log private methods subclassed. So, if you have a <code>DummyClass</code> with <code>-(void)_dummyMethod</code> as private and then a <code>DummySubClass</code> with a <code>-(void)_dummyMethod</code> implementation, the message will not be logged.</p> <p><strong>For iOS, this works only on Simulator.</strong></p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload