美文网首页
Dbug NSLog

Dbug NSLog

作者: 张家杰仔 | 来源:发表于2017-04-06 10:43 被阅读5次
    #ifdef DEBUG
    #define NSLog(FORMAT, ...) fprintf(stderr,"文件名:%s 行数:%d 输出:%s\n",[[[NSString stringWithUTF8String:__FILE__] lastPathComponent] UTF8String], __LINE__, [[NSString stringWithFormat:FORMAT, ##__VA_ARGS__] UTF8String])
    #else
    #define NSLog(...)
    #endif
    

    相关文章

      网友评论

          本文标题:Dbug NSLog

          本文链接:https://www.haomeiwen.com/subject/cautattx.html