深拷贝、浅拷贝

浅拷贝 nsstring * [email protected]”jack”;  常量区,没有产生新的对象 nsstring * str2=[str1 copy]; 深拷贝 1、nsmutablestring *str1=[nsmutablestring stringwithformat:@”jack”];   在堆区       nsmutablestring *str2=[str1 copy]
相关文章
相关标签/搜索