How do I debug with NSLog(@“Inside of the iPhone Simulator”)?

后端 未结 6 1831
爱一瞬间的悲伤
爱一瞬间的悲伤 2020-12-04 05:09

I\'m used to programming and having log messages be viewable. I know you used to be able to use NSLog() to trace out messages when debugging Cocoa applications.

6条回答
  •  青春惊慌失措
    2020-12-04 05:27

    Paste this in your prefix header. ALL logs from project will dissappear for sure .

    #ifndef __OPTIMIZE__
    
    #    define NSLog(...) NSLog(__VA_ARGS__)
    
    #else
    
    #    define NSLog(...) {}
    
    #endif
    

提交回复
热议问题