It has kind of become a habit of mine to log to console at almost every method for easy bug tracking. However, using NSLog doesn't show you what method unless you do something like:
Which is rather cumbersome when you add logging to many methods. This is where my savior comes into the picture.
By adding the following to your "MyApp-Prefix.pch" file in the "Supporting Files"-group
// DLog is almost a drop-in replacement for NSLog
you can use ALog (always log) and DLog (debug log) for a rich debug logging.
Simply putting DLog(); in your viewDidAppear method will output something like:
[MainViewController viewDidAppear:] [Line 169]
The blog post where I found this information is >>here