The problem of Memory Leak

When I turn ARC off ,I need to manage memory manually by myself.
I have some points.


First : 
myAttribute = XXX;//This kind of writing may cause some problem of memory leak;
//So ,my way is:
self.myAttribute = XXX;


Second :
When I new a window object ,
I should rewrite "delegateClass" by "nil" in "main" function.


Third : 
The problem of Memory Leak may cause by the version of the simulator.


Last:
The good tools are "Profile" and "Analyze". 
發佈了38 篇原創文章 · 獲贊 24 · 訪問量 9萬+
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章