CFShow()
是类似的,但没有前缀的东西.或者,正如wbyoung所说,使用NSLog()
.如果您不想使用Objective-C,则以下内容完全有效(尽管它需要链接到Foundation.framework):
#if __cplusplus
extern "C" {
#endif
void NSLog(CFStringRef format, ...);
void NSLogv(CFStringRef format, va_list args);
#if __cplusplus
}
#endif
int main (int argc, const char * argv[])
{
NSLog(CFSTR("Hello, World! %u"), 42);
return 0;
}
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
3874 次 |
最近记录: |