Over the time that I’ve been on StackOverflow, I’ve noticed that some users post their code with all of the releases still there although releasing is deprecated. By releasing, I mean something along the lines of:
[self.data release];
Why do users still do this? I know nothing about programming for older versions of iOS, and would love to do so, but when I try to release something in an app I’m building, I get either a deprecation error, or a warning. If what I just said is correct, how do I program for older versions? Also, how do I prevent these errors?
Well, bit of a broad question, and the straight forward answer is: go and read the documentation.
From documentation advanced memory management
Well, you are using the second method, but in those olden days programmers used manual- retain-release.. And some old school people (count me as one) still uses them..
The transition to ARC release notes will walk through this transition..
EDIT: some additions (first posted as comment, but thought better add it in answer..)
If you started first at ARC, then that is the way to go. Manual reference counting is difficult/confusing at first, but once learned will help you get a deep understanding of how memory is managed at core level (and trust me that will improve your confidence level as a iOS programmer). Remember that what ARC does is automatically adding this retain/release calls at compile time. So retain release calls are still there, it is just that you don’t have to worry about it.
You can be an iOS developer without understanding Manual Retain Release paradigm, but nothing bad (and plenty of good) will happen if you learn them.. Something for you to read at bed time.