自定义日志

1
2
3
4
5
6
7
#ifdef DEBUG
#define YZLog(...) \
NSLog(@"\n%@第%d行:\n%@",[[NSString stringWithFormat:@"%s",__FILE__] lastPathComponent], __LINE__, [NSString stringWithFormat:__VA_ARGS__]);
#else
#define YZLog(...)
#define NSLog(...)
#endif

最好放到PrefixHeader.pch里面