标签:
Pch文件内添加:
#ifdef DEBUG // 调试阶段 #define CHLog(...) NSLog(@"%s %d\n %@", __func__, __LINE__, [NSString stringWithFormat:__VA_ARGS__]) #else // 发布阶段 #define CHLog(...) #endif
如果嫌打印太多可设置为:
#define CHLog(...) NSLog(__VA_ARGS__)
标签:
原文地址:http://www.cnblogs.com/happyplane/p/4713909.html