摘要:
网上看到一篇文章,分析initWithString和initWithFormat的区别,用一下他的用例。下面是测试代码:NSString* str =[[NSStringalloc]initWithString:@"this is from initWithString function"];NSLog(@"this is from [[NSString alloc] initWithString] m_addr is %ld retainCount is %i", str, [strretainCount]);[strrelease];[strrele 阅读全文