In Praise of ARC
In Praise of ARC
- Subject: In Praise of ARC
- From: Philip McIntosh <email@hidden>
- Date: Sat, 05 Nov 2011 15:39:01 -0600
I am impressed with the implementation of Automatic Reference Counting (ARC) in iOS 5 and the conversion tool built into XCode 4.2. I have an app that generated a small leak each time I ran a "cycle" of the app. This was no doubt caused by a design flaw since no matter how much I attended to my retain/release cycles I could not get rid of one left over NSDecimalNumber at the end of each operation.
I took the plunge and refactored the project to use ARC in XCode. There were some very scary moments that generated many red warning flags, but I just kept doing it, and after I did it 4 times all the problems cleared themselves. That was a scary thing to do though.
I just checked the app with instruments, and sure enough, the memory leaks are gone.
Nice job Apple.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden